/* ==========================================================================
   ЕГОРЧИК.РФ — Urban Grunge / Cinematic Writer Portfolio
   ========================================================================== */

:root {
  --bg-black: #08090c;
  --bg-card: #121319;
  --bg-card-hover: #191b24;
  --bg-glass: rgba(18, 19, 25, 0.85);
  --accent-red: #c91b1f;
  --accent-red-bright: #e62227;
  --accent-red-glow: rgba(201, 27, 31, 0.35);
  --text-main: #f2f4f8;
  --text-muted: #959aa5;
  --border-subtle: #20232e;
  --border-active: #3a3f50;
  
  --font-body: "Manrope", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: "Bebas Neue", sans-serif;
  --font-serif: "Playfair Display", serif;
  --font-script: "Pacifico", cursive;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  background-color: var(--bg-black);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Background Film Texture */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle at 80% 20%, rgba(201, 27, 31, 0.08), transparent 45%),
                    radial-gradient(circle at 20% 80%, rgba(30, 40, 60, 0.15), transparent 50%);
  pointer-events: none;
  z-index: 0;
}

.wrapper {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 9, 12, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: #fff;
}

.logo-gk {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  background: #000;
  border: 1.5px solid var(--accent-red);
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.95rem;
  color: #fff;
  box-shadow: 0 0 12px var(--accent-red-glow);
}

.logo-script {
  font-family: var(--font-script);
  font-size: 1.45rem;
  color: var(--accent-red);
  text-shadow: 0 0 15px rgba(201, 27, 31, 0.4);
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.nav a:hover,
.nav a.is-active {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: #fff;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.35rem;
  align-items: center;
  justify-content: center;
}

/* Hero Section */
.hero-section {
  padding: 3rem 0 4rem;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(201, 27, 31, 0.12);
  border: 1px solid var(--accent-red);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0.4rem 0.9rem;
  border-radius: 20px;
  margin-bottom: 1.25rem;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 7vw, 5.2rem);
  line-height: 0.95;
  color: #fff;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero-title span {
  color: var(--accent-red);
  display: block;
}

.hero-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  line-height: 1.6;
  color: #d2d7e2;
  border-left: 3px solid var(--accent-red);
  padding-left: 1.25rem;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.6rem;
  min-height: 50px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.25s ease;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent-red);
  color: #fff;
  border: none;
  box-shadow: 0 4px 20px var(--accent-red-glow);
}

.btn-primary:hover {
  background: var(--accent-red-bright);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(201, 27, 31, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  border: 1px solid var(--border-subtle);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

.hero-media {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.1);
  background: #000;
}

.hero-media img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.hero-media:hover img {
  transform: scale(1.02);
}

.hero-media-tag {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(8, 9, 12, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  font-size: 0.85rem;
  color: #e0e4ec;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Sections */
.section {
  padding: 4rem 0;
  border-top: 1px solid var(--border-subtle);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 2.25rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-kicker {
  color: var(--accent-red);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 0.35rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  color: #fff;
  letter-spacing: 0.5px;
}

.section-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.2s ease;
}

.section-link:hover {
  color: #fff;
}

/* Poems Grid */
.poems-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.poem-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
}

.poem-card:hover {
  border-color: var(--accent-red);
  transform: translateY(-4px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6), 0 0 20px var(--accent-red-glow);
  background: var(--bg-card-hover);
}

.poem-card-cover {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
  background: #000;
  border-bottom: 1px solid var(--border-subtle);
}

.poem-card-body {
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.poem-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.6rem;
  line-height: 1.3;
}

.poem-card-excerpt {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  flex: 1;
}

.poem-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.85rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.poem-btn-link {
  color: var(--accent-red);
  font-weight: 700;
}

/* Feature Book Banner */
.book-banner {
  background: linear-gradient(135deg, #14161f 0%, #0c0d12 100%);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 2.5rem;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.book-banner::before {
  content: "“";
  position: absolute;
  top: -2rem;
  right: 1rem;
  font-family: var(--font-serif);
  font-size: 14rem;
  color: rgba(255, 255, 255, 0.03);
  pointer-events: none;
}

.book-tag {
  color: var(--accent-red);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
}

.book-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4vw, 3.4rem);
  color: #fff;
  line-height: 1;
  margin-bottom: 1rem;
}

.book-desc {
  font-size: 1rem;
  line-height: 1.65;
  color: #c4c9d4;
  margin-bottom: 1.5rem;
}

.book-meta-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.75rem;
}

.book-meta-list li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: #e0e4ee;
  font-size: 0.95rem;
}

.book-meta-list li::before {
  content: "✓";
  color: var(--accent-red);
  font-weight: 800;
}

/* Cinema / Projects Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}

.project-card:hover {
  border-color: var(--accent-red);
  transform: translateY(-4px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6), 0 0 20px var(--accent-red-glow);
}

.project-card-img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  background: #000;
}

.project-card-content {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.project-badge {
  font-size: 0.7rem;
  color: var(--accent-red);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.35rem;
}

.project-card-name {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

.project-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 1rem;
  flex: 1;
}

.project-card-action {
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.75rem;
}

/* Audio Love Channel Card */
.audio-highlight-card {
  background: radial-gradient(circle at 10% 50%, rgba(201, 27, 31, 0.25), transparent 60%),
              var(--bg-card);
  border: 1px solid var(--accent-red);
  border-radius: 16px;
  padding: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  box-shadow: 0 0 30px rgba(201, 27, 31, 0.15);
}

.audio-info h3 {
  font-family: var(--font-display);
  font-size: 2.4rem;
  color: #fff;
  letter-spacing: 1px;
  margin-bottom: 0.4rem;
}

.audio-info p {
  color: #d0d5e0;
  font-size: 1rem;
  max-width: 600px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 3rem 0;
  background: #050608;
  text-align: center;
}

.footer-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  color: #e0e4ec;
  margin-bottom: 0.6rem;
}

.footer-sub {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.footer-copy {
  color: #606575;
  font-size: 0.8rem;
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
  .hero-section {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2rem 0 3rem;
  }
  .book-banner {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 1.75rem;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(8, 9, 12, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
    flex-direction: column;
    padding: 1.25rem;
    gap: 0.5rem;
    align-items: stretch;
  }
  .nav.is-open {
    display: flex;
  }
  .nav a {
    font-size: 1.1rem;
    padding: 0.8rem 1rem;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .audio-highlight-card {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ==========================================================================
   AUTHENTIC MASTER LAYOUT & URBAN HERO COMPONENT STYLES
   ========================================================================== */

/* Desktop Master Hero Stage (>= 1024px) */
.desktop-hero-stage {
  display: block;
  max-width: 1280px;
  margin: 1.5rem auto 2.5rem;
  padding: 0 1rem;
}

.stage {
  position: relative;
  width: 100%;
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.stage img {
  display: block;
  width: 100%;
  height: auto;
}

.hotspot {
  position: absolute;
  display: block;
  z-index: 10;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.hotspot:hover {
  outline: 2px solid var(--accent-red);
  box-shadow: 0 0 25px var(--accent-red-glow), inset 0 0 15px rgba(201, 27, 31, 0.25);
  background: rgba(201, 27, 31, 0.12);
}

/* Mobile & Tablet Urban Hero (< 1024px) */
.mobile-urban-hero {
  display: none;
  padding: 2rem 1.25rem 3rem;
  max-width: 720px;
  margin: 0 auto;
}

.urban-hero-card {
  background: radial-gradient(circle at 50% 20%, rgba(201, 27, 31, 0.15), transparent 70%),
              var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
}

.urban-author-frame {
  position: relative;
  width: 170px;
  height: 170px;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  padding: 5px;
  background: linear-gradient(135deg, var(--accent-red), rgba(255, 255, 255, 0.1));
  box-shadow: 0 0 30px var(--accent-red-glow);
}

.urban-author-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  border-radius: 50%;
  background: #000;
  display: block;
}

.urban-author-badge {
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  background: #000;
  border: 1.5px solid var(--accent-red);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  white-space: nowrap;
}

.urban-author-name {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 3.4rem);
  line-height: 0.95;
  color: #fff;
  letter-spacing: 1px;
  margin-bottom: 0.25rem;
}

.urban-author-script {
  font-family: var(--font-script);
  font-size: 1.75rem;
  color: var(--accent-red);
  margin-bottom: 0.85rem;
  text-shadow: 0 0 15px rgba(201, 27, 31, 0.5);
}

.urban-tags {
  font-size: 0.8rem;
  font-weight: 700;
  color: #a0a6b5;
  letter-spacing: 1.5px;
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.urban-credo-box {
  background: rgba(0, 0, 0, 0.4);
  border-left: 3px solid var(--accent-red);
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin-bottom: 1.75rem;
  text-align: left;
}

.credo-line {
  font-family: var(--font-serif);
  font-style: italic;
  color: #e2e6f0;
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
}

.credo-line:last-child {
  margin-bottom: 0;
}

/* Torn Paper Portfolio Section */
.portfolio-torn-section {
  position: relative;
  padding: 3.5rem 0 4.5rem;
  background: #f4f5f8;
  color: #11141a;
  border-top: 4px solid #fff;
  border-bottom: 4px solid #fff;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
}

.portfolio-header-block {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 2.25rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.portfolio-main-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  color: #0b0c10;
  letter-spacing: 1px;
  line-height: 0.95;
}

.portfolio-sub-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--accent-red);
  letter-spacing: 2px;
  margin-top: 0.35rem;
}

.portfolio-lead-text {
  color: #4a5060;
  font-size: 0.95rem;
  margin-top: 0.35rem;
}

.portfolio-all-link {
  color: var(--accent-red);
  font-weight: 800;
  font-size: 0.95rem;
  text-decoration: none;
  border-bottom: 2px solid var(--accent-red);
  padding-bottom: 2px;
  transition: opacity 0.2s ease;
}

.portfolio-all-link:hover {
  opacity: 0.8;
}

.portfolio-cards-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.portfolio-item-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid #e2e5ec;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
}

.portfolio-item-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.16);
  border-color: var(--accent-red);
}

.portfolio-item-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16/10;
  background: #111;
  overflow: hidden;
}

.portfolio-item-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portfolio-item-tag {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  background: rgba(11, 12, 16, 0.85);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.portfolio-item-details {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.portfolio-item-name {
  font-family: var(--font-display);
  font-size: 1.45rem;
  color: #11141a;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.portfolio-item-meta {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-red);
  margin-bottom: 0.4rem;
}

.portfolio-item-role {
  font-size: 0.85rem;
  color: #606778;
  line-height: 1.4;
}

/* Footer Book Bar */
.footer-book-bar {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

/* Responsive Switches */
@media (max-width: 1023px) {
  .desktop-hero-stage {
    display: none;
  }
  .mobile-urban-hero {
    display: block;
  }
}

@media (max-width: 600px) {
  .portfolio-cards-row {
    grid-template-columns: 1fr;
  }
}
