/* =====================================================
   CSS VARIABLES (LOCKED DESIGN SYSTEM)
===================================================== */
:root {
  --header-bg: #040C64;
  --footer-bg: #040C64;
  --side-bg:   #3F4353;
  --body-bg:   #CED2D7;

  --text-main: #0A0A0A;
  --text-light:#FFFFFF;
  --text-muted:#6B7280;

  --accent:    #F59E0B; /* gold */
}

/* =====================================================
   RESET / BASE
===================================================== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--body-bg);
  color: var(--text-main);
  font-family: 'Libre Baskerville', Georgia, serif;
  line-height: 1.7;
}

:root {
  --header-height: 88px;
}
/* =====================================================
   GLOBAL CONTAINER (RESPONSIVE)
===================================================== */
.container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0 16px;
}

/* =====================================================
   TYPOGRAPHY
===================================================== */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, serif;
  margin-top: 0;
}

/* =====================================================
   HEADER (LOCKED)
===================================================== */
header {
  background: var(--header-bg);
  color: var(--text-light);
  padding: 0.6rem 1.5rem 0.6rem 0.6rem;
  border-bottom: 4px solid var(--accent);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-left {
  display: flex;
  align-items: center;
  gap: .6rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.search {
  display: flex;
  align-items: center;
}

/* Logo */
.logo-link {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  text-decoration: none;
}

.logo-img {
  height: 36px;
  width: auto;
  display: block;
}

.logo-text {
  font-family: 'Pacifico', cursive;
  font-size: 1.3rem;
  color: var(--text-light);
  white-space: nowrap;
}

/* Navigation */
nav a {
  color: var(--text-light);
  text-decoration: none;
  margin-right: 1rem;
  font-family: 'Inter', system-ui, sans-serif;
}

nav a:hover {
  text-decoration: underline;
}

/* Search */
.search {
  display: flex;
  align-items: center;
}

.search input {
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
  border: none;
  font-family: 'Inter', system-ui, sans-serif;
}

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
}


/* User / Coins */
/* User / Coins */
.user-ui {
  display: flex;
  align-items: center;
  gap: 8px;

  font-family: 'Inter', system-ui, sans-serif;
  color: rgba(255, 255, 255, 0.85);
}



.user-ui a {
  color: #FFD700;
  text-decoration: none;
  font-weight: 800;
}


.header-logout {
  color: #FFD700;
  font-weight: 800;
  position: relative;
  z-index: 3;
}

.user-ui a:hover {
  text-decoration: underline;
}

.coins {
  color: var(--accent);
  font-weight: 600;
}



/* =====================================================
   HEADER PROFILE LINK (AVATAR + USERNAME)
===================================================== */



.header-profile-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: 0.6rem;
  text-decoration: none;
  color: var(--text-light);
}

.header-profile-link:hover {
  text-decoration: underline;
}

/* Avatar circle */
.header-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;

  background-color: #FFD700; /* gold / yellow */
  color: #000000;            /* black initial */

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 1.5rem;
  font-weight: 1000;

  overflow: hidden;
}

/* Avatar image */
.header-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Initials fallback */
.header-avatar .avatar-initials {
  font-size: 0.9rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
}

/* Username text */
.header-username {
  font-size: 1rem;
  font-weight: 1000;
  white-space: nowrap;
  
}

/* =====================================================
   HAMBURGER MENU
===================================================== */

.hamburger {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: 8px;
}

.hamburger span {
  width: 22px;
  height: 2px;
  background: #ffffff;
  display: block;
}


/* =====================================================
   PAGE LAYOUT
===================================================== */
.side {
  background: var(--side-bg);
  color: var(--text-light);
  padding: 1rem;
}


/* =====================================================
   BUTTONS
===================================================== */
.btn-pill-primary {
  display: inline-block;
  padding: 0.55rem 1.4rem;
  border-radius: 999px;

  background: var(--header-bg);
  color: var(--text-light);
  text-decoration: none;

  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.95rem;
  font-weight: 500;

  border: none;
  cursor: pointer;

  transition: background-color 0.2s ease, transform 0.15s ease;
}

.btn-pill-primary:hover {
  background: #5f6db0;
  transform: translateY(-1px);
}

.btn-pill-secondary {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;

  background: #515E92; /* same as category pill */
  color: #ffffff;

  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.75rem;
  font-weight: 500;

  border: none;
  cursor: pointer;
  text-decoration: none;

  transition: background-color 0.2s ease, transform 0.15s ease;
}

.btn-pill-secondary:hover {
  background: #5f6db0;
  transform: translateY(-1px);
}

.btn-pill-secondary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Header block */
.featured-head {
    margin-bottom: 10px !important;
}

.featured-title {
    font-size: 18px !important;
    font-weight: 600 !important;
    margin-bottom: 2px !important;
}

.featured-sub {
    font-size: 13px !important;
    color: #555 !important;
    margin: 0 !important;
}

/* Category chips container */
.category-list {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    margin: 10px 0 16px !important;
}

/* Category chip buttons */
.category-chip {
    display: inline-block !important;
    padding: 6px 12px !important;
    border-radius: 16px !important;
    border: 1.5px solid #f4a100 !important;
    background: #f4a100 !important;
    text-decoration: none !important;
    color: #0b1a5e !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    transition: all 0.2s ease !important;
}

/* Hover state */
.category-chip:hover {
    background: #d98c00 !important;
    color: #fff !important;
}
/* =====================================================
   STORY WRITE SECTION (CORRECT HIERARCHY)
===================================================== */
.story-write {
  margin-bottom: 1.5rem;
}

/* Prompt */
.story-prompt {
  font-family: 'Pacifico', cursive;
  font-size: 1.3rem;
  font-weight: 400;
  color: #1f2937;
  letter-spacing: 0.4px;
  margin-bottom: 0.75rem;
  
}

/* Writing canvas ONLY */
.story-canvas {
  background: #ffffff;
  border: 2px solid var(--accent);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
}

/* Textarea */
.story-input {
    width: 100%;
    min-height: 700px;
    padding: 20px;

    font-family: Georgia, serif;
    font-size: 18px;
    line-height: 1.7;

    border: 1px solid #000;
    border-radius: 6px;

    background: #fff;

    overflow-y: auto;
white-space: normal;
    word-break: break-word;

    outline: none;
    
}

#storyEditor p {
    margin: 0;
}

#storyEditor h1,
#storyEditor h2,
#storyEditor h3,
#storyEditor h4 {
    margin: 0.5em 0;
}
/* CTA row */
.story-meta {
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

/* Guidance outside the canvas */
.story-guidance {
  margin-top: 0.6rem;
  margin-left: 0.25rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* =====================================================
   STORIES FEED
===================================================== */
.stories-feed {
  margin-top: 2.5rem;
}

.stories-empty {
  font-size: 1rem;
}

/* =====================================================
   FOOTER
===================================================== */
footer {
  background: var(--footer-bg);
  color: var(--text-light);
  text-align: center;
  padding: 1rem;
  font-family: 'Inter', system-ui, sans-serif;
  border-top: 4px solid var(--accent);
}


/* =====================================================
   HOMEPAGE HYBRID – PHASE 1 (19-02)
===================================================== */

.home-phase1 {
  width: 100%;
  max-width: none;
  margin: .2rem 0 0;
  padding: 0 1rem;
  display: grid;
  gap: 2rem;
  align-items: stretch;
   font-family: 'Pacifico', cursive;
}


/* LEFT COLUMN */
.home-main {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (max-width: 900px) {

  .home-pill {
    flex-direction: column;
    align-items: flex-start;
    border-radius: 20px;
       font-family: 'Pacifico', cursive;
  }

.pill-text {
  width: 100%;
  max-width: 100%;
}

.pill-text h1,
.pill-text h2 {
      margin: 0;
  font-size: 0.85rem;
  line-height: 1;
  word-break: break-word;
}


}


/* =====================
   WRITING PILL
===================== */
.home-pill {
    
  border-radius: 10px;
  padding: .5rem .5rem;
  border: 1px solid var(--accent);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .2rem;
}

.pill-text h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
}

.pill-action {
  flex-shrink: 0;
}

/* =====================
   FEATURED ORIGINALS
===================== */
.featured-originals h3 {
  font-family: 'Playfair Display', serif;
  margin-bottom: 0.8rem;
}

.featured-note {
  font-family: 'Pacifico', cursive;
  font-size: 1.25rem;
  color: var(--header-bg); /* strong brand blue */
  font-weight: 500;
  margin-left: 10px;
}

.originals-grid {
  display: flex;
  flex-wrap: wrap;

  gap: 1.6rem;

  align-items: flex-start;
}

/* Featured Originals – match Self-Published size */
.original-card {
  width: 200px;
}

.original-card img {
  width: 120px;
  height: 150px;
  object-fit: cover;
  border-radius: 14px;

  /* same premium look as aspiration */
  border: 2px solid var(--accent);
  box-shadow:
    0 12px 26px rgba(0,0,0,0.15),
    inset 0 0 0 1px rgba(255,255,255,0.4);
}

/* Book title formatting */
.original-card h4 {
  font-size: 0.85rem;
  line-height: 1.3;
  margin: 0.35rem 0 0.15rem;
  font-family: 'Playfair Display', serif;
}

/* Author formatting */
.original-card p {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
}

/* Professional card container */
.original-card {
  width: 160px;
  background: #ffffff;
  border-radius: 18px;
  padding: 0.6rem;
  border: 2px solid var(--accent);

  box-shadow:
    0 10px 24px rgba(0,0,0,0.12);

  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.original-card:hover {
  transform: translateY(-3px);
  box-shadow:
    0 14px 28px rgba(0,0,0,0.18);
}

/* Cover */
.original-cover img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  border-radius: 14px;
}

/* Text block */
.original-meta {
  margin-top: 0.5rem;
}

/* Title */
.original-meta h4 {
  font-size: 0.9rem;
  line-height: 1.3;
  margin: 0 0 0.15rem;
}

/* Author */
.original-meta p {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
}
/* =====================
   AUTHOR VISION BLOCK
===================== */
.author-vision {
  background: #EAF2FF;
  border-radius: 20px;
  padding: .5rem;
border: 3px solid #040C64;

  /* important change */
  align-self: start;

  /* keep it compact */
  height: fit-content;
  max-width: 320px;
  margin-left: 0;
width: 90%;

  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  text-align: center;
}


.author-vision h3 {
  margin: 0.2rem 0 0.2rem;
  font-size: 1.1rem;
}


.author-vision h3:not(:first-child) {
  margin-top: 0.3rem;
}

.author-vision h3 + .post-pill {
  margin-top: 2px;
}
.author-vision p {
  font-size: 0.95rem;
  margin: 0.7rem 0;
}


/* =====================
   MOBILE
===================== */
@media (max-width: 900px) {

  .home-phase1 {
    padding: 0 1rem;
  }

  .home-pill {
    flex-direction: column;
    align-items: flex-start;
  }

  .pill-action {
    width: 100%;
  }

  .pill-action a {
    display: inline-block;
  }
  
  
}

/* Featured Originals – Mobile */
@media (max-width: 900px) {

.originals-grid {
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)) !important;
  gap: 12px !important;
}

  .original-card {
    width: 100%;
  }

  .original-cover img {
    height: 190px; /* slightly smaller for mobile */
  }

}

/* CTA card mobile */
@media (max-width: 900px) {

  .aspiration-book {
    width: 100%;
  }

  .aspiration-cover {
    height: 190px;
  }

}


/* =====================================================
   HOME PAGE (ISOLATED NO GLOBAL IMPACT)
=====================================================*/

/* HERO SECTION */
.home-hero {
  margin-top: 1rem;
  margin-bottom: 1rem;
}

/* =====================================================
   VALUE STRIP (READ · WRITE · EARN · WITHDRAW)
===================================================== */
.value-strip {
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 8px 0;
  font-size: 10px;
  font-weight: 600;
  color: var(--header-bg);
   font-family: 'Pacifico', cursive;
}

.value-strip span {
  position: relative;
}

/* Dot separator */
.value-strip span:not(:last-child)::after {
  content: "·";
  margin-left: 8px;
  color: #999;
}
.home-hero h1 {
  font-family: 'Pacifico', cursive;
  font-size: 1.8rem;
  font-weight: 400;          /* thinner stroke */
  line-height: 1.4;
  color: #00037;
  letter-spacing: 0.5px;
}

/* THREE BLOCK LAYOUT */
.home-blocks {
  margin: 3rem auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  max-width: 1000px;
}

main.content {
  margin-top: var(--header-height);
}

/* CARD */
.home-block
{
  background: #ffffff;     /* header color */
  border-radius: 16px;
  padding: 1.1rem 1rem;
  min-height: 250px;
  border-bottom: 4px solid var(--accent);
border-top: 4px solid var(--accent);


  /* subtle depth */
  box-shadow: inset 0 0 18px rgba(0,0,0,0.15);
}

/* CARD HEADLINES THE 3 LINES */
.home-block h2 {
  font-size: 1.5rem;
  font-weight: 400;          /* slightly stronger than hero */
  line-height: 1.45;
  color: #000000;
  margin-bottom: 0.8rem;
   -webkit-text-stroke: .5px #FF9000;
}

/* SUPPORTING TEXT */
.home-block p {
  font-family: 'Pacifico';
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1.8;
  color: #333333;
  margin-bottom: 1.2rem;
}

/* LINKS */
.home-block a {
  font-family: 'Pacifico', cursive;
  font-size: 1.5rem;
  font-weight: 500;
   font-style: italic;
  color: #1f3a8a;
   -webkit-text-stroke: .5 #2f678c
  text-decoration: underline;
}

html, body {
  height: 100%;
  margin: 0;
}

body {
  display: flex;
  flex-direction: column;
}

main.content {
  flex: 1;
}

/* Footer always pushed down */
main.content {
  flex: 1 0 auto;
}

footer {
  margin-top: auto;
}

/* =========================
   PROFILE PAGE — FINAL
   Pills only. No panels.
========================= */

.profile-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 16px 64px;
  color: #2b2b2b;
}

/* =========================
   MAIN PILL STYLE
========================= */
.profile-page .pill {
  background: linear-gradient(180deg, #fbf8f3 0%, #f3eee5 100%);
  border-radius: 28px;
  padding: 28px 32px;
  margin-bottom: 32px;
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.08),
    inset 0 0 0 1px rgba(214, 179, 106, 0.6);
}

/* =========================
   HERO PILL
========================= */
.pill-hero {
  display: flex;
  align-items: center;
  gap: 24px;
}



.avatar-pill {
  width: 64px;              /* ↓ reduced from 96px */
  height: 64px;
  border-radius: 50%;
  overflow: hidden;         /* ✅ CRITICAL */
  background: radial-gradient(circle at top, #ffffff 0%, #f1ebdf 70%);
  border: 2px solid #d6b36a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 600;
  flex-shrink: 0;
}

.avatar-pill img {
  width: 100%;
  height: 100%;
  object-fit: cover;        /* ✅ CRITICAL */
  object-position: center;
  display: block;
}

.hero-center h1 {
  margin: 0 0 6px;
  font-size: 30px;
  font-weight: 600;
}

.tagline {
  margin: 0 0 10px;
  color: #6b6b6b;
}

.stats-row {
  display: flex;
  gap: 18px;
  font-size: 14px;
  color: #6b6b6b;
}



/* =========================
   MIDDLE ROW (ABOUT + COMMENTS)
========================= */
.profile-middle {
  display: grid;
  grid-template-columns: 2fr 1.2fr;
  gap: 32px;
}

/* =========================
   INNER PILLS
========================= */
.question-pill,
.comment-pill,
.post-pill {
  background: rgba(255, 255, 255, 0.65);
  border-radius: 18px;
  padding: 16px 18px;
  margin-top: 16px;
  box-shadow:
    inset 0 0 0 1px rgba(214, 179, 106, 0.25);
}

.recent-comments {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.recent-comment-item {
  background: #E6F1F7;
  border-radius: 14px;
  padding: 12px 14px;

  border: 1.5px solid #000000; /* ✅ black border */
}


.recent-comment-meta {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.recent-comment-content {
  margin-top: 6px;
  font-size: 0.9rem;
  line-height: 1.5;
}

.recent-comment-date {
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.recent-post-link {
  color: #1d4ed8;      /* blue */
  font-weight: 700;    /* bold */
  text-decoration: underline;
}

.recent-post-link:hover {
  color: #1e40af;
}

.recent-post-type {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 4px;
}


/* =========================
   FORM ELEMENTS
========================= */
.profile-page label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 6px;
}

.profile-page input,
.profile-page textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #dcdcdc;
  font-size: 14px;
  background: #ffffff;
}

.profile-page input:focus,
.profile-page textarea:focus {
  outline: none;
  border-color: #d6b36a;
  box-shadow: 0 0 0 2px rgba(214, 179, 106, 0.25);
}

/* =========================
   BUTTONS (GOLD)
========================= */
.btn-pill {
  margin-top: 14px;
  padding: 10px 22px;
  border-radius: 999px;
  background: linear-gradient(180deg, #f7e6b8 0%, #d6b36a 100%);
  color: #3a2a10;
  border: 1px solid #b8944a;
  font-size: 14px;
  cursor: pointer;
}

.btn-pill:hover {
  background: linear-gradient(180deg, #d6b36a 0%, #b8944a 100%);
}

.popular-post-item {
  margin-bottom: 6px;
}

.popular-post-link {
  color: #1d4ed8;
  font-weight: 700;
  text-decoration: underline;
}

.popular-post-link:hover {
  color: #1e40af;
}

.popular-post-type {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 4px;
}

.popular-post-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}


/* =========================
   POSTS SECTION
========================= */
.pill-posts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

/* =========================
   EMPTY TEXT
========================= */
.empty-state {
  font-size: 14px;
  color: #777;
}


/* ===============================
   PROFILE LAYOUT (LEFT GUTTER)
================================ */

.profile-layout {
  display: flex;
  align-items: flex-start;
  gap: 10px; /* tighter, ~¼ inch */
}

/* Main profile stays centered */
.profile-page {
  flex: 1;
  max-width: 1600px;
}


/* ===============================
   COINS PILL (ACTUAL PILL)
================================ */
.floating-coins {
  width: 240px;
  min-width: 240px;

  background: #74b3ce;
  border-radius: 22px;
  padding: 20px;
   align-items: center;

  border: 2px solid #000000; /* ✅ black border */

  box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

/* Align coins pill with hero username */
.floating-coins {
  margin-top: 10px; 
   align-items: center;/* matches .profile-page top padding */
}


/* Coin stats */
.coin-stat-pill {
  background: #fff;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 10px;
  text-align: center;
}
.coin-stat-row{
    display:flex;
    gap:10px;
}

.coin-stat-row .coin-stat{
    flex:1;
}

.coin-label {
  display: block;
  font-size: 12px;
  opacity: 0.7;
}

.coin-value {
  font-size: 20px;
  font-weight: 700;
}

/* Divider */
.coin-divider {
  border: none;
  height: 1px;
  background: #ddd;
  margin: 12px 0;
}


 .coin-cta-pill {
  padding: 10px 14px;      /* reduce height */
  font-size: 0.9rem;      /* smaller text */
  border-radius: 14px;    /* slightly tighter */
  margin-top: 8px;
}

.coin-cta-pill.secondary {
  margin-top: 6px;
}



 /* ===============================
   COINS PILL – VERTICAL STACK
================================ */

/* Top action links */
.floating-coins a {
  display: block;
  margin-bottom: 6px;

  font-weight: 800;
  color: #000000; /* gold */
  text-decoration: none;
}

.floating-coins a:hover {
  text-decoration: underline;
}

/* History buttons */
.floating-coins .coin-action-pill {
  display: block;
  width: 100%;
  margin-bottom: 6px;
}

.coin-history-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.coin-action-pill::before,
.coin-action-pill::after {
  content: none !important;
  display: none !important;
}

/* =====================================================
   GLOBAL SEARCH — FINAL STYLES (LOCKED)
===================================================== */

/* -----------------------------
   MAIN SEARCH PILL (DO NOT TOUCH)
----------------------------- */
.search.global-search.search-pill {
  background: #ffffff;
  padding: 6px 10px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  position: relative;

  border: 2px solid var(--accent); /* gold border */
}

.search.global-search.search-pill input {
  background: transparent;
  border: none;
  outline: none;
  color: #000000;
  font-size: 0.9rem;
  width: 180px;
}

.search.global-search.search-pill input::placeholder {
  color: #555555;
}

/* -----------------------------
   DROPDOWN CONTAINER (BLUE)
----------------------------- */
.search.global-search.search-pill .search-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 100%;

  background: var(--header-bg);
  border-radius: 20px;
  padding: 10px;

  z-index: 3000;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.3);
}

/* -----------------------------
   RESULT PILLS (WHITE / LATEX)
----------------------------- */
.search.global-search.search-pill .search-item {
  background: #ffffff;
  color: #000000;

  padding: 10px 14px;
  margin-bottom: 8px;
  border-radius: 999px;

  border: 1.5px solid #000000;

  display: flex;
  justify-content: space-between;
  align-items: center;

  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.search.global-search.search-pill .search-item:last-child {
  margin-bottom: 0;
}

.search.global-search.search-pill .search-item:hover {
  background: #f9fafb;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Result text */
.search.global-search.search-pill .search-label {
  font-weight: 700;
  font-size: 0.9rem;
  color: #000000;
}

.search.global-search.search-pill .search-type {
  font-size: 0.65rem;
  color: #000000;
  opacity: 0.6;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* -----------------------------
   EMPTY STATE (ON BLUE)
----------------------------- */
.search.global-search.search-pill .search-empty {
  padding: 12px;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.85);
}

/* COLLAPSIBLE STORY EDITOR */
.story-toggle {
  font-family: 'Pacifico', cursive;
  font-size: 1.2rem;
  cursor: pointer;
  margin-bottom: 0.8rem;
}





/* -----------------------------
   7/2
----------------------------- */
/* =====================================================
   HEADER — MOBILE STABILITY
===================================================== */
@media (max-width: 900px) {

  .header-inner {
    flex-wrap: wrap;
  }

  .header-left {
    width: 100%;
  }

  .header-right {
    width: 100%;
    justify-content: space-between;
    margin-top: 6px;
  }

 /* Show hamburger */
.hamburger {
  display: flex;
}

/* Hide nav by default on mobile */
nav {
  display: none;
  flex-direction: column;
  width: 100%;
  background: var(--header-bg);
  padding: 8px 0;
  order: 3;
}

/* Open state */
nav.open {
  display: flex;
}

nav a {
  padding: 8px 16px;
  margin: 0;
}


  .search {
    width: 100%;
  }

  .search input {
    width: 100%;
  }
}



/* =====================================================
   GRID — MOBILE RESPONSIVENESS
===================================================== */
@media (max-width: 900px) {

  /* Home page blocks */
  .home-blocks {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  /* Profile layout */
  .profile-middle {
    grid-template-columns: 1fr;
  }

  /* Posts section */
  .pill-posts {
    grid-template-columns: 1fr;
  }

  /* Floating coins panel should stack */
@media (max-width: 900px) {
    .profile-layout {
        flex-direction: column;
        align-items: center;
    }
}
}
@media (max-width: 900px) {

  .floating-coins {
    width: 80%;
    min-width: auto;
 align-items: center;
    padding: 8px;
    border-radius: 8px;
     align-items: center;
  }

  .floating-coins h3 {
    margin: 0 0 10px;
    font-size: 1.6rem;
  }

  .coin-divider {
    margin: 8px 0;
  }
}

/* Move hamburger to the right */
.hamburger {
  margin-left: auto;
}


/* =====================================================
   MOBILE TYPOGRAPHY + READING COMFORT
===================================================== */
@media (max-width: 900px) {

  body {
    font-size: 16px;
    line-height: 1.8;
  }

  h1 {
    font-size: 1.6rem;
  }



  h3 {
    font-size: 1.2rem;
  }

  /* Reduce heavy script fonts on small screens */
  .home-hero h1,
  .home-block h2,
  .home-block p {

  }
  
  .featured-note {
  font-family: 'Pacifico', cursive;
  font-weight: 500;
  color: var(--header-bg);
}
}


@media (max-width: 900px) {

  .story-canvas {
    padding: 1rem;
  }

  .story-input {
    font-size: 1rem;
    line-height: 1.8;
  }

  main.content {
    padding: 0 12px;
    margin-top: 120px; /* Keeps your mobile header from overlapping content */
  }

}

@media (max-width: 900px) {

  .profile-page {
    padding: 20px 12px 48px;
  }

  .pill {
    padding: 20px;
  }

  .home-block {
    min-height: auto;
    padding: 1.6rem;
  }
  
  
  
}

.aspiration-cover {
  width: 100%;
  max-width: 120px;
  height: 150px;
  margin: 0 auto;
  border-radius: 14px;

  /* Premium book border */
  border: 2px solid var(--accent);

  /* Soft book shadow */
  box-shadow:
    0 12px 26px rgba(0,0,0,0.15),
    inset 0 0 0 1px rgba(255,255,255,0.4);

  /* Subtle book texture */
  background:
    linear-gradient(145deg, #2e2787 100%),
    url("https://www.transparenttextures.com/patterns/paper-fibers.png");

  background-blend-mode: multiply;

  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;

  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 600;
  color: #ffffff;

  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Creator CTA card container */
.aspiration-book {
  width: 175px;
  background: #ffffff;
  border-radius: 18px;
  padding: 0.6rem;
  border: 2px solid var(--accent);

  box-shadow:
    0 10px 24px rgba(0,0,0,0.12);

  display: block;
  text-decoration: none;
  color: inherit;

  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.aspiration-book:hover {
  transform: translateY(-3px);
  box-shadow:
    0 14px 28px rgba(0,0,0,0.18);
}

/* CTA link text */
.aspiration-cta {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--header-bg);
}

/* STORIES DISCOVERY — MOBILE COMFORT */

@media (max-width: 900px) {

  .author-vision {
    width: 70%;
    max-width: 300px;

    margin: 8px 0 0;

    padding: 8px;          /* ↓ reduced */
    border-width: 2px;      /* ↓ lighter */

    justify-self: start;
    text-align: left;
  }
}
@media (max-width: 900px) {

  .author-vision .post-pill {
    padding: 10px 12px;
      margin-bottom: 8px;
  }

  .author-vision h3 {
    font-size: 1.1rem;
    margin-bottom: 6px;
  }
  
  
}
@media (max-width: 900px) {

  .author-vision h3 + .post-pill {
    margin-bottom: 4px;
  }

}

}

}

/* =========================================
   MOBILE CATEGORY STRIP (Stories page)
========================================= */

/* =========================================
   MOBILE CATEGORY STRIP (Stories page)
========================================= */

/* Hide hamburger by default (desktop) */
.mobile-category-toggle {
  display: none;
}

/* MOBILE ONLY */
@media (max-width: 900px) {

  /* Show hamburger */
  .mobile-category-toggle {
    display: block !important;
    position: fixed;
    left: 10px;
    top: 100px;
    z-index: 100;
    font-size: 1.5rem;
    background: #515E92;
    color: #ffffff;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
  }

  /* Hide vertical strip */
  .categories-strip {
    display: none !important;
  }

  /* Show strip when open */
  .categories-strip.open {
    display: flex !important;
  }
}

/* STORIES — WRITING CANVAS (DESKTOP) */
@media (min-width: 901px) {

  .story-write {
    margin-left: calc(64px + 2rem);
    max-width: 760px;
  }

  .story-canvas {
    background: #ffffff;
    border: 2px solid var(--accent);
    border-radius: 14px;

    padding: 2rem;

    box-shadow: 
      0 12px 28px rgba(0,0,0,0.12);
  }

}

@media (max-width: 900px) {

  .story-meta{
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .story-meta select{
    width: 100%;
  }

  .story-meta > div{
    display: flex;
    gap: 10px;
    justify-content: flex-start;
  }

}

@media (max-width:900px){

  .originals-main *{
    margin-left:0 !important;
  }
}
@media (max-width: 900px) {

  [id^="chapter-content-"] {

    position: relative;

    width: 100%;
    margin: 16px auto;

    padding: 18px 16px;

    /* ✅ WARM PAPER */
    background: #ffffff !important;

    border-radius: 14px;

    /* GOLD FRAME */
    border: 2px solid #000000 !important;

    box-shadow: 0 12px 30px rgba(0,0,0,0.12);

    max-height: 65vh;
    overflow-y: auto;

    -webkit-overflow-scrolling: touch;
  }
  
  


}

@media (min-width: 1000px) {

  [id^="chapter-content-"] {

    max-width: 1000px;
    width: 100%;

    /* 👇 shift slightly left */
    margin: 20px auto 20px 120px;

    padding: 32px 36px;

    background: #ffffff !important;

    border-radius: 16px;

    border: 10px solid rgba(180,140,90,0.3) !important;

    box-shadow: 0 10px 30px rgba(0,0,0,0.08);

    max-height: none;
    overflow: visible;
  }

}

@media (min-width: 720px) {

  .chapter-header,
  .chapter-title {

    max-width: 720px;
    width: 100%;

     margin: 20px auto 20px 120px  !important;


  }

}

/* ONLY affects category pages */
.category-page .original-cover {
  display: block !important;
  width: 100% !important;
}

.category-page .originals-grid {
  display: flex !important;
  flex-wrap: wrap !important;

  gap: 20px !important;

  align-items: flex-start !important;
}
.category-page .original-cover img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border-radius: 12px !important;
  display: block !important;
}

.category-page .original-card {
  padding: 8px !important;
}

/* REMOVE the "outer box feel" */
.category-page .original-card {
  position: relative !important;
  padding: 0 !important;
  margin: 0 !important;
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 16px !important;
  overflow: hidden !important;
  max-width: 110px !important;
}

/* MAKE IMAGE THE CARD */
.category-page .category-cover {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
}

.category-page .share-circle {
  position: absolute !important;
  bottom: 8px !important;
  right: 8px !important;

  width: 28px !important;
  height: 28px !important;

  background: #e6f2ff !important; /* light blue */
  border: 1.5px solid #b3d7ff !important;
  border-radius: 50% !important;

  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  cursor: pointer !important;
  transition: all 0.2s ease !important;
}
.category-page .category-cover img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
  border-radius: 16px !important;
}

/* SHARE ON IMAGE */
.category-page .share-circle {
  position: absolute !important;
  bottom: 8px !important;
  right: 8px !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 6px !important;
  background:#87CEEB !important;
  color: #fffff !important;
  border: #000000 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: .5rem !important;
}


.category-page .story-box {
  position: relative;
  display: flex;
  align-items: flex-end;

  height: 250px;
  
  width: 160px;
  padding: 1px;
  border-radius: 14px;

  text-decoration: none;
  color: #ffffff;

  /* 🎬 BALANCED CINEMATIC */
  background:
    radial-gradient(circle at 70% 25%, rgba(255,255,255,0.18), transparent 45%),
    linear-gradient(150deg, #333333, #004C99, #020617);

  /* 🎯 softer depth */
  box-shadow:
    inset 0 0 30px rgba(0,0,0,0.4),
    0 6px 12px rgba(0,0,0,0.2);

  border: 1.5px solid rgba(245,158,11,0.7);
   /* 🔥 THIS FIXES YOUR ISSUE */
  overflow: hidden;
}


/* =========================
   CATEGORY PILLS
========================= */

.category-pills {
  display: flex;
  gap: 10px;
  margin: 12px 0 20px;
  flex-wrap: wrap;
}

/* Pill button */
.category-pills .pill {
  padding: 6px 14px;
  border: 1.5px solid #f4a100;
  border-radius: 20px;
  font-size: 13px;
  text-decoration: none;
  color: #1a1a5e;
  background: #fff;
  font-weight: 500;
  transition: all 0.2s ease;
  white-space: nowrap;
}

/* Hover */
.category-pills .pill:hover {
  background: #f4a100;
  color: #fff;
  transform: translateY(-1px);
}

/* Active click feel */
.category-pills .pill:active {
  transform: scale(0.96);
}

/* =========================
   MOBILE TWEAK
========================= */

@media (max-width: 600px) {
  .category-pills {
    gap: 8px;
    margin-bottom: 16px;
  }

  .category-pills .pill {
    font-size: 12px;
    padding: 5px 12px;
  }
}

/* =========================
   FIX TEXT WRAPPING
========================= */

.story-content h4 {
  font-size: 13px !important;
  line-height: 1.3 !important;
  margin-bottom: 4px !important;
  text-align: left !important;

  word-break: break-word !important;
  overflow-wrap: break-word !important;
}

.story-content p {
  font-size: 11px !important;
  line-height: 1.3 !important;
  opacity: 0.85 !important;
  text-align: left !important;

  /* 🔥 REMOVE nowrap */
  white-space: normal !important;

  word-break: break-word !important;
  overflow-wrap: break-word !important;
}

.chapter-text {
  font-family: "Book Antiqua", "Palatino Linotype", Georgia, serif !important;

  font-size: 18px !important;
  line-height: 1.45 !important;

  color: #000 !important;
}

/* Normalize ALL elements inside */
.chapter-text * {
  font-family: inherit !important;
  font-size: inherit !important;
  line-height: inherit !important;
  color: inherit !important;
}

/* Paragraph spacing */
.chapter-text p {
  margin: 0 0 0.6em 0 !important;
}

/* Remove weird first gap */
.chapter-text p:first-child {
  margin-top: 0 !important;
}

@media (max-width: 768px) {
  .chapter-text {
    font-size: 16px !important;
    line-height: 1.4 !important;
  }

  .chapter-text p {
    margin-bottom: 0.5em !important;
  }
  
  .chapter-text p:empty {
  display: none !important;
}
}

.original-card {
    position: relative;
}

.content-badge {
    position: absolute;

    top: 2px;
    right: 2px;

    padding: 5px;

    background: #fff;

    border: 1.5px solid #000;

    border-radius: 555px;

    display: flex;
    align-items: center;
    justify-content: center;

    z-index: 10;

    line-height: 0;
}
.content-badge img {
    width: 20px;
    height: 20px;

    object-fit: contain;
}

.publish-cta{
    margin-top:8px;
    padding:2px 2px;
    border-radius:24px;
    border:2px solid rgba(255,255,255,0.10);
    background:#ffffff;

    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:1px;
    flex-wrap:wrap;
}

@media (max-width: 900px){

    .home-phase1{
        flex-direction:column;
    }

    .home-sidebar{
        width:100%;
    }

    .originals-grid{
        display:grid;
        gap:16px;
    }

    .original-card{
        width:100%;
        max-width:100%;
    }

    .original-cover img{
        width:100%;
        height:auto;
        display:block;
    }

}

#paypal-highlight-box {
  border-radius: 12px;
}

.paypal-highlight {
  border: 3px solid #f4b400;
  border-radius: 12px;
  padding: 12px;

  animation: paypalPulse 1.2s infinite;
}

@keyframes paypalPulse {

  0% {
    box-shadow: 0 0 0 0 rgba(244,180,0,.7);
  }

  70% {
    box-shadow: 0 0 0 15px rgba(244,180,0,0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(244,180,0,0);
  }

}

.cookie-banner{
    position:fixed;
    bottom:0;
    left:0;
    right:0;
    background:#1f2937;
    color:#fff;
    padding:15px;
    z-index:99999;
    box-shadow:0 -2px 10px rgba(0,0,0,.2);
}

.cookie-content{
    max-width:1200px;
    margin:0 auto;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:15px;
}

.cookie-text{
    font-size:14px;
    line-height:1.5;
}

.cookie-text a{
    color:#f4d03f;
}

.cookie-buttons{
    display:flex;
    gap:10px;
}

.cookie-buttons button{
    border:none;
    padding:8px 14px;
    border-radius:4px;
    cursor:pointer;
}

#cookie-accept{
    background:#2ecc71;
    color:white;
}

#cookie-reject{
    background:#555;
    color:white;
}

@media(max-width:768px){

    .cookie-content{
        flex-direction:column;
        text-align:center;
    }

}

footer {
    color: #ffffff;
}

footer a {
    color: #ffffff;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

@media (min-width: 901px) {

    .story-write {
        max-width: 1400px;
        width: calc(100% - 120px);
    }

    .story-canvas {
        max-width: none;
        width: 100%;
    }

}

.writer-manifesto-container {
  margin: 15px auto 25px;
  max-width: 1200px;
  padding: 0 10px;
  box-sizing: border-box;
}

.writer-manifesto-wrapper {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 10px;
}

/* Hide native scrollbars */
.writer-manifesto-wrapper::-webkit-scrollbar {
  display: none;
}

.manifesto-card {
  flex: 0 0 210px; /* Perfect width to see the next card peeking in on mobile */
  scroll-snap-align: start;
  background: #FFFDF9; /* Warm paper tint */
  border: 1px solid #F59E0B; /* Matches your brand amber accent */
  border-radius: 14px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.manifesto-badge {
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: #515E92; /* Matches your structural blue tone */
  margin-bottom: 6px;
}

.manifesto-card p {
  margin: 0;
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 0.75rem;
  color: #4B5563;
  line-height: 1;
}

.manifesto-swipe-hint {
  font-size: 0.65rem;
  color: #9CA3AF;
  text-align: right;
  margin-top: -4px;
  padding-right: 6px;
  font-family: system-ui, sans-serif;
}

/* Desktop optimization to unroll the horizontal scroll into a beautiful grid */
@media (min-width: 901px) {
  .writer-manifesto-wrapper {
    overflow-x: visible;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
  }
  .manifesto-card {
    flex: initial;
  }
  .manifesto-swipe-hint {
    display: none;
  }
}