
/* =========================================
   BOOKS PAGE — MOHAMMAD MUSHIR ALAM SHAIKH
   Standalone stylesheet
========================================= */

:root {
  --navy: #101d32;
  --navy-light: #192b45;
  --cream: #f8f5ee;
  --paper: #fffdf8;
  --gold: #c6a66b;
  --gold-light: #e1cc9e;
  --text: #252c36;
  --muted: #777b82;
  --border: #e8e1d5;
  --white: #ffffff;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "DM Sans", Arial, sans-serif;
}

/* Reset */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

body {
  min-width: 320px;
  background: var(--paper);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

::selection {
  background: var(--gold-light);
  color: var(--navy);
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}

/* Shared containers */

.header-container,
.section-container,
.footer-container {
  width: min(1180px, calc(100% - 64px));
  margin-inline: auto;
}

/* =========================================
   HEADER
========================================= */

.site-header {
  position: relative;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid rgba(16, 29, 50, 0.08);
}

.header-container {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.brand-mark {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: var(--gold-light);
  font-family: var(--serif);
  font-size: 27px;
  border-radius: 2px;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.5;
}

.brand-copy strong {
  color: var(--navy);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.25px;
}

.brand-copy small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 3px;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 27px;
}

.primary-nav > a {
  position: relative;
  color: #555d68;
  font-size: 12px;
  font-weight: 600;
  transition: color 0.25s ease;
}

.primary-nav > a:not(.nav-cta)::after {
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  height: 1px;
  background: var(--gold);
  content: "";
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.primary-nav > a:hover,
.primary-nav > a.active {
  color: var(--navy);
}

.primary-nav > a:hover::after,
.primary-nav > a.active::after {
  transform: scaleX(1);
}

.primary-nav > a.nav-cta {
  padding: 12px 16px;
  background: var(--navy);
  color: var(--white);
  transition:
    background 0.25s ease,
    color 0.25s ease;
}

.primary-nav > a.nav-cta:hover {
  background: var(--gold);
  color: var(--navy);
}

.nav-cta span {
  margin-left: 8px;
}

.menu-toggle {
  display: none;
  width: 43px;
  height: 43px;
  padding: 11px;
  border: 1px solid var(--border);
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  margin: 5px 0;
  background: var(--navy);
}

/* =========================================
   SHARED TYPOGRAPHY
========================================= */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: #927443;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2.3px;
}

.eyebrow-line {
  width: 30px;
  height: 1px;
  background: var(--gold);
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 500;
}

h1 em,
h2 em {
  color: var(--gold);
  font-weight: 400;
}

/* =========================================
   HERO
========================================= */

.books-hero {
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(
      circle at 78% 42%,
      rgba(198, 166, 107, 0.11),
      transparent 31%
    ),
    var(--cream);
}

.hero-container {
  width: min(1180px, calc(100% - 64px));
  min-height: 580px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  align-items: center;
  gap: 55px;
  padding-block: 75px;
}

.hero-copy {
  max-width: 570px;
  animation: reveal-up 0.8s ease both;
}

.hero-copy h1 {
  margin-top: 24px;
  color: var(--navy);
  font-size: clamp(45px, 5.2vw, 70px);
  line-height: 1.12;
  letter-spacing: -2px;
}

.hero-copy > p {
  max-width: 470px;
  margin-top: 24px;
  color: #69717b;
  font-size: 14px;
  line-height: 1.95;
}

.button {
  display: inline-flex;
  min-height: 51px;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 0 22px;
  font-size: 12px;
  font-weight: 700;
  transition:
    background 0.25s ease,
    color 0.25s ease,
    transform 0.25s ease;
}

.button:hover {
  transform: translateY(-3px);
}

.button-primary {
  margin-top: 31px;
  background: var(--navy);
  color: var(--white);
}

.button-primary:hover {
  background: var(--gold);
  color: var(--navy);
}

.button span {
  font-size: 16px;
}

/* =========================================
   DECORATIVE BOOK ART
========================================= */

.hero-art {
  min-height: 430px;
  position: relative;
  display: grid;
  place-items: center;
  isolation: isolate;
}

.art-circle {
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(198, 166, 107, 0.35);
  border-radius: 50%;
}

.art-circle-one {
  width: 350px;
  height: 350px;
}

.art-circle-two {
  width: 430px;
  height: 430px;
  border-color: rgba(16, 29, 50, 0.09);
}

.book-stack {
  position: relative;
  width: 300px;
  height: 365px;
  perspective: 1000px;
  animation: book-float 5s ease-in-out infinite;
}

.book {
  position: absolute;
  width: 235px;
  height: 335px;
  display: flex;
  flex-direction: column;
  box-shadow: 18px 22px 35px rgba(16, 29, 50, 0.17);
}

.book-back {
  top: 18px;
  right: 0;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: #c6a66b;
  color: var(--navy);
  transform: rotate(8deg);
}

.book-back .book-rule {
  width: 42px;
  height: 1px;
  margin-bottom: 22px;
  background: var(--navy);
}

.book-back .book-title {
  font-family: var(--serif);
  font-size: 37px;
}

.book-back .book-caption {
  margin-top: 10px;
  font-size: 7px;
  letter-spacing: 1.2px;
}

.book-front {
  top: 12px;
  left: 0;
  align-items: center;
  padding: 25px 17px;
  border-left: 7px solid #0b1424;
  background:
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.04),
      transparent 60%
    ),
    var(--navy);
  color: var(--cream);
  text-align: center;
  transform: rotate(-5deg);
}

.book-brand {
  align-self: flex-start;
  color: var(--gold-light);
  font-size: 10px;
  letter-spacing: 3px;
}

.book-divider {
  width: 42px;
  height: 1px;
  margin-top: 44px;
  background: var(--gold);
}

.book-main-title {
  margin-top: 19px;
  font-family: var(--serif);
  font-size: 34px;
  line-height: 1.2;
}

.book-subtitle {
  margin-top: 14px;
  color: var(--gold-light);
  font-size: 7px;
  letter-spacing: 1px;
}

.book-author {
  margin-top: auto;
  color: #e7dcc7;
  font-size: 7px;
  letter-spacing: 1px;
}

.art-caption {
  position: absolute;
  bottom: -1px;
  color: #8a806d;
  font-size: 9px;
  letter-spacing: 2px;
  text-align: center;
}

/* =========================================
   LIBRARY INTRO
========================================= */

.library-intro {
  padding-block: 110px;
  background: var(--paper);
}

.library-intro .section-container {
  display: grid;
  grid-template-columns: 1fr 0.8fr;
  align-items: center;
  gap: 100px;
}

.section-heading h2 {
  margin-top: 20px;
  color: var(--navy);
  font-size: clamp(35px, 4vw, 49px);
  line-height: 1.22;
  letter-spacing: -1px;
}

.intro-copy {
  padding-left: 28px;
  border-left: 1px solid var(--gold);
}

.intro-copy p {
  color: #6d747c;
  font-size: 13px;
  line-height: 2;
}

.intro-copy p + p {
  margin-top: 17px;
}

/* =========================================
   BOOK COLLECTION
========================================= */

.book-collection {
  padding-block: 95px 105px;
  background: var(--cream);
}

.collection-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 25px;
  margin-bottom: 48px;
}

.collection-heading h2 {
  margin-top: 11px;
  color: var(--navy);
  font-size: clamp(32px, 4vw, 43px);
  line-height: 1.25;
}

.collection-count {
  padding-bottom: 7px;
  color: #8b7a5e;
  font-size: 11px;
  letter-spacing: 2px;
}

.book-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 27px;
}

.book-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(16, 29, 50, 0.08);
  background: var(--paper);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.book-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 38px rgba(16, 29, 50, 0.09);
}

.cover {
  min-height: 345px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 27px;
  color: var(--cream);
  text-align: center;
}

.cover::before,
.cover::after {
  position: absolute;
  content: "";
  pointer-events: none;
}

.cover::before {
  inset: 14px;
  border: 1px solid rgba(225, 204, 158, 0.48);
}

.cover::after {
  width: 190px;
  height: 190px;
  right: -85px;
  bottom: -100px;
  border: 1px solid rgba(225, 204, 158, 0.45);
  border-radius: 50%;
  box-shadow:
    0 0 0 20px rgba(225, 204, 158, 0.05),
    0 0 0 40px rgba(225, 204, 158, 0.04);
}

.cover-one {
  background:
    radial-gradient(
      circle at 20% 80%,
      rgba(198, 166, 107, 0.18),
      transparent 40%
    ),
    #152742;
}

.cover-two {
  background:
    radial-gradient(
      circle at 80% 20%,
      rgba(198, 166, 107, 0.18),
      transparent 40%
    ),
    #35413d;
}

.cover-three {
  background:
    radial-gradient(
      circle at 20% 20%,
      rgba(198, 166, 107, 0.2),
      transparent 40%
    ),
    #4a3029;
}

.cover-index,
.cover-small,
.cover-author {
  position: absolute;
  z-index: 1;
  font-size: 8px;
  letter-spacing: 1.8px;
}

.cover-index {
  top: 28px;
  left: 29px;
  color: var(--gold-light);
}

.cover-small {
  top: 31px;
  right: 28px;
  color: #e3d7bf;
  font-size: 7px;
  letter-spacing: 1px;
}

.cover-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cover-symbol {
  margin-bottom: 19px;
  color: var(--gold-light);
  font-size: 32px;
  line-height: 1;
}

.cover-content h3 {
  color: var(--cream);
  font-size: clamp(27px, 3vw, 35px);
  line-height: 1.2;
}

.cover-content p {
  margin-top: 19px;
  color: var(--gold-light);
  font-size: 7px;
  letter-spacing: 1.5px;
}

.cover-author {
  bottom: 30px;
  color: #e7dcc7;
  font-size: 7px;
}

.book-info {
  padding: 26px 25px 28px;
}

.book-status {
  display: inline-block;
  padding: 5px 9px;
  border: 1px solid #e6dcc8;
  color: #8a7043;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1.3px;
}

.book-info h3 {
  margin-top: 15px;
  color: var(--navy);
  font-size: 23px;
  line-height: 1.35;
}

.book-info > p {
  margin-top: 12px;
  color: #737981;
  font-size: 12px;
  line-height: 1.9;
}

.book-note {
  display: block;
  margin-top: 19px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  color: #8b806f;
  font-size: 10px;
  line-height: 1.7;
}

.collection-disclaimer {
  max-width: 800px;
  margin: 32px auto 0;
  color: #777b82;
  font-size: 11px;
  line-height: 1.8;
  text-align: center;
}

/* =========================================
   AUTHOR CTA
========================================= */

.author-cta {
  overflow: hidden;
  background: var(--navy);
  color: var(--cream);
}

.cta-container {
  width: min(1180px, calc(100% - 64px));
  min-height: 360px;
  position: relative;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 45px;
  padding-block: 75px;
}

.cta-copy {
  position: relative;
  z-index: 1;
  max-width: 580px;
}

.cta-copy .eyebrow {
  color: var(--gold-light);
}

.cta-copy h2 {
  margin-top: 18px;
  font-size: clamp(39px, 4.5vw, 56px);
  line-height: 1.2;
}

.cta-copy p {
  max-width: 470px;
  margin-top: 17px;
  color: #c2c9d2;
  font-size: 13px;
  line-height: 1.9;
}

.button-light {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  background: var(--gold-light);
  color: var(--navy);
}

.button-light:hover {
  background: var(--white);
}

.cta-decoration {
  position: absolute;
  right: 65px;
  bottom: -130px;
  color: rgba(255, 255, 255, 0.035);
  font-family: var(--serif);
  font-size: 390px;
  line-height: 1;
  pointer-events: none;
}

/* =========================================
   FOOTER
========================================= */

.site-footer {
  padding-top: 38px;
  background: #0b1525;
  color: var(--cream);
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.3px;
}

.footer-mark {
  width: 37px;
  height: 37px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--gold-light);
  font-family: var(--serif);
  font-size: 22px;
}

.footer-note {
  margin-top: 13px;
  color: #aab2bf;
  font-size: 11px;
}

.footer-bottom {
  min-height: 75px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 15px 25px;
  margin-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p,
.back-to-top {
  color: #aab2bf;
  font-size: 10px;
}

.powered-by a {
  color: var(--gold-light);
  transition: color 0.2s ease;
}

.powered-by a:hover {
  color: var(--white);
}

.back-to-top:hover {
  color: var(--gold-light);
}

/* =========================================
   ANIMATIONS
========================================= */

@keyframes reveal-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes book-float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-9px);
  }
}

/* =========================================
   RESPONSIVE — TABLETS
========================================= */

@media (max-width: 1000px) {
  .header-container,
  .section-container,
  .footer-container,
  .hero-container,
  .cta-container {
    width: min(100% - 44px, 760px);
  }

  .header-container {
    min-height: 78px;
  }

  .primary-nav {
    gap: 16px;
  }

  .primary-nav > a {
    font-size: 11px;
  }

  .hero-container {
    min-height: 530px;
    gap: 20px;
  }

  .hero-copy h1 {
    font-size: 54px;
  }

  .hero-art {
    transform: scale(0.88);
  }

  .library-intro .section-container {
    gap: 45px;
  }

  .book-grid {
    gap: 18px;
  }

  .cover {
    min-height: 310px;
    padding: 20px;
  }

  .book-info {
    padding: 22px 18px;
  }
}

/* =========================================
   RESPONSIVE — MOBILE NAVIGATION
========================================= */

@media (max-width: 760px) {
  .header-container,
  .section-container,
  .footer-container,
  .hero-container,
  .cta-container {
    width: calc(100% - 40px);
  }

  .header-container {
    min-height: 74px;
  }

  .brand-mark {
    width: 39px;
    height: 39px;
    font-size: 24px;
  }

  .brand-copy strong {
    font-size: 10px;
  }

  .brand-copy small {
    font-size: 9px;
  }

  .menu-toggle {
    position: relative;
    z-index: 102;
    display: block;
  }

  .primary-nav {
    position: fixed;
    z-index: 101;
    inset: 74px 0 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    overflow-y: auto;
    padding: 25px 24px 40px;
    background: var(--paper);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition:
      opacity 0.25s ease,
      visibility 0.25s ease,
      transform 0.25s ease;
  }

  .primary-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .primary-nav > a {
    padding: 17px 4px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
  }

  .primary-nav > a:not(.nav-cta)::after {
    display: none;
  }

  .primary-nav > a.nav-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    padding: 15px 18px;
    border-bottom: 0;
  }

  /* Hero */

  .hero-container {
    grid-template-columns: 1fr;
    gap: 10px;
    padding-block: 65px 50px;
  }

  .hero-copy {
    max-width: 600px;
  }

  .hero-copy h1 {
    font-size: clamp(45px, 10vw, 62px);
    letter-spacing: -1.5px;
  }

  .hero-copy > p {
    font-size: 13px;
  }

  .hero-art {
    min-height: 420px;
    margin-top: 10px;
    transform: scale(0.94);
  }

  /* Intro */

  .library-intro {
    padding-block: 75px;
  }

  .library-intro .section-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .section-heading h2 {
    font-size: 42px;
  }

  .intro-copy {
    padding-left: 20px;
  }

  /* Collection */

  .book-collection {
    padding-block: 70px;
  }

  .collection-heading {
    align-items: flex-start;
    margin-bottom: 32px;
  }

  .collection-heading h2 {
    font-size: 34px;
  }

  .collection-count {
    padding-top: 8px;
    font-size: 9px;
  }

  .book-grid {
    grid-template-columns: 1fr;
    gap: 27px;
  }

  .cover {
    min-height: 390px;
  }

  .cover-content h3 {
    font-size: 39px;
  }

  .book-info {
    padding: 25px;
  }

  .book-info h3 {
    font-size: 25px;
  }

  /* CTA */

  .cta-container {
    min-height: auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 28px;
    padding-block: 70px;
  }

  .cta-copy h2 {
    font-size: 45px;
  }

  .cta-decoration {
    right: -15px;
    bottom: -75px;
    font-size: 280px;
  }

  /* Footer */

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding-block: 22px;
  }
}

/* =========================================
   SMALL MOBILE
========================================= */

@media (max-width: 400px) {
  .header-container,
  .section-container,
  .footer-container,
  .hero-container,
  .cta-container {
    width: calc(100% - 32px);
  }

  .brand {
    gap: 8px;
  }

  .brand-copy strong {
    font-size: 9px;
    letter-spacing: 0.7px;
  }

  .brand-copy small {
    letter-spacing: 2px;
  }

  .hero-copy h1 {
    font-size: 43px;
  }

  .hero-art {
    min-height: 365px;
    transform: scale(0.8);
    margin-inline: -25px;
  }

  .section-heading h2 {
    font-size: 36px;
  }

  .collection-heading h2 {
    font-size: 30px;
  }

  .cover {
    min-height: 340px;
  }

  .book-info {
    padding: 21px;
  }

  .cta-copy h2 {
    font-size: 39px;
  }
}

/* =========================================
   REDUCED MOTION ACCESSIBILITY
========================================= */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
