﻿/*
Theme Name: Cosmos Is Love
Theme URI: https://cosmos-is-love.ru/
Author: Cosmos Is Love
Description: Dark WordPress theme for a cosmism manifesto. The front page renders post/page ID 46 directly, with a subtle animated graph background.
Version: 1.1.1
Requires at least: 6.8
Tested up to: 7.0
Requires PHP: 8.1
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: cosmos-is-love
Tags: dark, one-column, custom-menu, custom-logo, responsive-layout
*/

:root {
  --bg: #050505;
  --bg-2: #0a0a09;
  --text: #eeeeea;
  --muted: #aaa7a0;
  --dim: #74716b;
  --ghost: #3f3f3b;
  --line: rgba(238, 238, 234, 0.12);
  --line-2: rgba(238, 238, 234, 0.2);
  --accent: #b8aa86;
  --max: 900px;
  --wide: 1180px;
  --radius: 8px;
  --wp--style--global--content-size: 820px;
  --wp--style--global--wide-size: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 19px;
  line-height: 1.72;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -4;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.045), transparent 28rem),
    linear-gradient(180deg, #080807 0%, #050505 52%, #080807 100%);
}

a {
  color: #d5c59d;
  text-decoration-color: rgba(213, 197, 157, 0.42);
  text-underline-offset: 0.22em;
}

a:hover,
a:focus {
  color: #f0e2bd;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

.skip-link:focus {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 20;
  width: auto;
  height: auto;
  padding: 0.65rem 0.9rem;
  clip: auto;
  color: #050505;
  background: #eee;
  border-radius: var(--radius);
}

/* Header */

.site-shell {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
}

.site-header {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(238, 238, 234, 0.08);
  background: rgba(5, 5, 5, 0.72);
  backdrop-filter: blur(16px);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(var(--wide), calc(100% - 2rem));
  min-height: 64px;
  margin: 0 auto;
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  color: var(--text);
  text-decoration: none;
}

.site-title {
  display: block;
  overflow: hidden;
  color: var(--text);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.05rem, 1.8vw, 1.42rem);
  font-weight: 500;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0.35rem 0.65rem;
  color: var(--muted);
  font-size: 0.86rem;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--radius);
}

.site-nav a:hover,
.site-nav a:focus {
  color: var(--text);
  border-color: var(--line);
  background: rgba(238, 238, 234, 0.04);
}

/* Manifest page */

.manifest-page {
  position: relative;
  min-height: 100vh;
  padding-top: 64px;
  overflow: hidden;
}

.manifest-graph {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.manifest-graph canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.manifest-page::after {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  content: "";
  background:
    linear-gradient(90deg, rgba(5, 5, 5, 0.72), rgba(5, 5, 5, 0.44) 50%, rgba(5, 5, 5, 0.66)),
    linear-gradient(180deg, rgba(5, 5, 5, 0.18), rgba(5, 5, 5, 0.82) 92%);
}

.manifest-page__inner {
  position: relative;
  z-index: 2;
  width: min(var(--wide), calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(5rem, 9vw, 8rem) 0 clamp(4rem, 8vw, 7rem);
}

.manifest-article {
  position: relative;
  width: min(var(--max), 100%);
}

.manifest-header {
  margin: 0 0 clamp(2rem, 5vw, 4rem);
}

.manifest-main-title {
  position: relative;
  display: inline-block;
  margin: 0;
  color: var(--text);
  font-family: Bahnschrift, "Arial Black", Impact, "Segoe UI Black", system-ui, sans-serif;
  font-size: clamp(3.2rem, 10vw, 9.6rem);
  font-stretch: condensed;
  font-weight: 900;
  letter-spacing: 0.035em;
  line-height: 0.82;
  text-transform: uppercase;
  text-wrap: balance;
  cursor: default;
  -webkit-text-stroke: 1px rgba(238, 238, 234, 0.22);
  text-shadow:
    0 0 1px rgba(238, 238, 234, 0.9),
    0.045em 0.045em 0 rgba(92, 92, 86, 0.38),
    -0.035em 0.07em 0 rgba(184, 170, 134, 0.16),
    0 0 2.5rem rgba(184, 170, 134, 0.12);
  transition:
    color 220ms ease,
    filter 220ms ease,
    text-shadow 220ms ease,
    transform 220ms ease;
}

.manifest-main-title:hover,
.manifest-main-title:active {
  color: #f8f4e8;
  background: linear-gradient(105deg, #f8f4e8 0%, #b8aa86 28%, #d8d8d0 46%, #7d8984 62%, #f8f4e8 100%);
  background-size: 260% 100%;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: cil-title-flow 1.9s linear infinite;
  filter: contrast(1.16) saturate(1.18);
  transform: translateY(-0.035em) skewX(-2deg);
  text-shadow:
    0 0 1px rgba(255, 255, 255, 0.95),
    0.05em 0.04em 0 rgba(184, 170, 134, 0.42),
    -0.04em 0.075em 0 rgba(120, 134, 130, 0.32),
    0 0 3rem rgba(213, 197, 157, 0.22);
}

@keyframes cil-title-flow {
  0% {
    background-position: 0% 50%;
  }

  100% {
    background-position: 260% 50%;
  }
}

/* Manifest content */

.manifest-content {
  position: relative;
  color: var(--text);
}

.manifest-content > * {
  position: relative;
  z-index: 2;
  max-width: var(--wp--style--global--content-size);
  margin-right: auto;
  margin-left: 0;
}

.manifest-content p {
  margin-top: 0;
  margin-bottom: 1.25em;
  color: #e3e0d9;
  text-align: justify;
  text-align-last: left;
  hyphens: none;
}

.manifest-content strong {
  color: #fff;
}

.manifest-content em {
  color: #f1e7cd;
}

.manifest-content blockquote {
  margin: 2rem 0;
  padding: 0.2rem 0 0.2rem 1.2rem;
  color: #eee8dc;
  border-left: 2px solid rgba(213, 197, 157, 0.65);
}

.manifest-content :where(h1, h2, h3, h4) {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: 0;
}

.manifest-content h2:not(.has-x-large-font-size):not(.has-xx-large-font-size),
.manifest-content h3:not(.has-x-large-font-size):not(.has-xx-large-font-size) {
  margin: 2.5em 0 0.75em;
  color: #f0eee8;
  line-height: 1.05;
}

.manifest-content h2 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.manifest-content h3 {
  font-size: clamp(1.55rem, 3vw, 2.35rem);
}

/*
 * Huge background headings from WordPress editor.
 * To make XL smaller, edit only font-size below.
 */
.manifest-content .has-x-large-font-size,
.manifest-content .has-xx-large-font-size,
.manifest-content .has-huge-font-size,
.manifest-content h1.has-x-large-font-size,
.manifest-content h2.has-x-large-font-size,
.manifest-content h3.has-x-large-font-size {
  z-index: 1;
  max-width: min(1120px, calc(100vw - 1rem));
  margin: clamp(3rem, 9vw, 7rem) 0 clamp(-3.8rem, -5vw, -1.8rem);
  transform: translateX(clamp(-4.5rem, -7vw, -1rem));
  color: rgba(238, 238, 234, 0.23) !important;
  font-size: clamp(4.32rem, 14.4vw, 12rem) !important;
  font-weight: 500 !important;
  letter-spacing: 0 !important;
  line-height: 0.72 !important;
  pointer-events: none;
  text-wrap: balance;
}

.manifest-content .has-x-large-font-size + p,
.manifest-content .has-xx-large-font-size + p,
.manifest-content .has-huge-font-size + p {
  margin-top: 0;
}

.manifest-content .alignwide {
  max-width: var(--wp--style--global--wide-size);
}

.manifest-content .alignfull {
  width: 100vw;
  max-width: none;
  margin-right: calc(50% - 50vw);
  margin-left: calc(50% - 50vw);
}

.manifest-content ul,
.manifest-content ol {
  padding-left: 1.25rem;
  color: #e3e0d9;
}

.manifest-content li {
  margin: 0.55rem 0;
}

.manifest-content hr,
.wp-block-separator {
  margin: 3rem 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.manifest-content :where(input:not([type="submit"]), textarea, select) {
  width: 100%;
  min-height: 46px;
  padding: 0.75rem 0.85rem;
  color: var(--text);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  background: rgba(238, 238, 234, 0.05);
}

.manifest-content :where(.wp-block-button__link, .wp-element-button, input[type="submit"], button[type="submit"]) {
  min-height: 46px;
  padding: 0.72rem 1rem;
  color: #050505;
  border-radius: var(--radius);
  background: #d5c59d;
}

/* Footer */

.site-footer {
  border-top: 1px solid rgba(238, 238, 234, 0.08);
  background: rgba(5, 5, 5, 0.88);
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(var(--wide), calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.2rem 0;
  color: var(--dim);
  font-size: 0.84rem;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0.42rem 0.62rem;
  color: var(--muted);
  font-size: 0.84rem;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(238, 238, 234, 0.035);
}

.social-links a:hover,
.social-links a:focus {
  color: var(--text);
  border-color: rgba(213, 197, 157, 0.45);
}

/* Fallback templates */

.content-band {
  padding-top: 64px;
}

.content-wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 7rem) 0;
}

.post-card {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.entry-header {
  padding-bottom: 2rem;
}

.entry-title {
  margin: 0;
  color: var(--text);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.4rem, 7vw, 6rem);
  font-weight: 500;
  line-height: 0.95;
}

.entry-label {
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.entry-content {
  color: var(--text);
}

/* Mobile */

@media (max-width: 760px) {
  body {
    font-size: 17px;
  }

  .site-header {
    position: sticky;
  }

  .site-header__inner {
    min-height: 58px;
  }

  .site-nav {
    display: none;
  }

  .manifest-page {
    padding-top: 0;
  }

  .manifest-page__inner {
    width: min(100% - 1.2rem, var(--wide));
    padding-top: clamp(3.5rem, 16vw, 5rem);
  }

  .manifest-main-title {
    font-size: clamp(3rem, 16vw, 5.2rem);
  }

  .manifest-content .has-x-large-font-size,
  .manifest-content .has-xx-large-font-size,
  .manifest-content .has-huge-font-size {
    margin: 3.2rem 0 -1.75rem;
    transform: translateX(-0.35rem);
    color: rgba(238, 238, 234, 0.2) !important;
    font-size: clamp(3.44rem, 20.8vw, 6.4rem) !important;
    line-height: 0.78 !important;
  }

  .site-footer__inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .social-links {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}



