/* ==========================================================================
   HandwritingMe 2.0 — Modern Minimalist Design System
   Award-winning UX/UI: Warm Editorial Paper, Refined Ink & Modern Craft
   ========================================================================== */

:root {
    --bg-canvas: #faf8f5;
    --bg-surface: #ffffff;
    --bg-subtle: #f3efe8;
    --bg-card-hover: #ffffff;
    
    --text-main: #1a1917;
    --text-muted: #666159;
    --text-light: #948e85;
    
    --border-color: #e6e0d5;
    --border-subtle: #f0ece3;
    --border-focus: #1b3b5a;
    
    --primary: #1b3b5a;
    --primary-hover: #12283e;
    --primary-light: #eef4f9;
    --primary-glow: rgba(27, 59, 90, 0.12);
    
    --accent-stamp: #b94a37;
    --accent-stamp-light: #fbeee9;
    --accent-gold: #c28835;
    --accent-green: #2d6a4f;
    --accent-green-light: #edf7f1;
    
    --font-serif: 'Newsreader', Georgia, 'Times New Roman', serif;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    
    --shadow-xs: 0 1px 2px rgba(26, 25, 23, 0.04);
    --shadow-sm: 0 2px 6px rgba(26, 25, 23, 0.04), 0 1px 3px rgba(26, 25, 23, 0.02);
    --shadow-md: 0 6px 18px rgba(26, 25, 23, 0.06), 0 2px 6px rgba(26, 25, 23, 0.03);
    --shadow-lg: 0 14px 34px rgba(26, 25, 23, 0.08), 0 4px 12px rgba(26, 25, 23, 0.03);
    
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 22px;
    --radius-full: 9999px;
    
    --container-max: 760px;
    --transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset & Global */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

body {
    min-height: 100%;
    background-color: var(--bg-canvas);
    color: var(--text-main);
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.65;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    width: 100%;
}

::selection {
    background: var(--primary);
    color: #fff;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
}

img, svg {
    display: block;
    max-width: 100%;
}

button, input, textarea, select {
    font: inherit;
    color: inherit;
}

/* ==========================================================================
   Header & Navigation Bar
   ========================================================================== */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    background: rgba(250, 248, 245, 0.88);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.site-header-inner {
    max-width: 860px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo-mark {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(27, 59, 90, 0.25);
    flex-shrink: 0;
    transition: var(--transition);
}

.brand-wrapper:hover .brand-logo-mark {
    transform: rotate(-6deg) scale(1.05);
}

.brand-text-group {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-family: var(--font-serif);
    font-size: 21px;
    font-weight: 600;
    color: var(--text-main);
    letter-spacing: -0.2px;
    line-height: 1.15;
}

.brand-subtitle {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.site-nav a.nav-link {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    padding: 7px 12px;
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.site-nav a.nav-link:hover {
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.04);
}

.site-nav a.nav-link.active {
    color: var(--primary);
    background: var(--primary-light);
    font-weight: 600;
}

.nav-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #fff !important;
    background: var(--primary);
    padding: 8px 16px;
    border-radius: var(--radius-full);
    box-shadow: 0 2px 6px rgba(27, 59, 90, 0.2);
    transition: var(--transition);
    margin-left: 6px;
}

.nav-cta:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(27, 59, 90, 0.28);
}

.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    padding: 6px;
    color: var(--text-main);
    cursor: pointer;
}

/* Mobile Nav Drawer */
.mobile-nav-drawer {
    display: none;
    padding: 12px 24px 20px 24px;
    background: var(--bg-canvas);
    border-bottom: 1px solid var(--border-color);
}

.mobile-nav-drawer.open {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mobile-nav-drawer a {
    padding: 10px 14px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
}

.mobile-nav-drawer a.active {
    color: var(--primary);
    background: var(--primary-light);
    font-weight: 600;
}

/* ==========================================================================
   Main Container & Layout
   ========================================================================== */

.main-content {
    flex: 1;
    max-width: var(--container-max);
    width: 100%;
    margin: 0 auto;
    padding: 40px 24px 80px 24px;
}

/* Hero Section (Home) */
.hero-statement {
    padding: 24px 0 44px 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 44px;
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: var(--accent-stamp);
    background: var(--accent-stamp-light);
    padding: 4px 10px;
    border-radius: var(--radius-full);
    margin-bottom: 18px;
}

.hero-statement h1 {
    font-family: var(--font-serif);
    font-size: 38px;
    font-weight: 500;
    line-height: 1.25;
    color: var(--text-main);
    margin-bottom: 16px;
    letter-spacing: -0.4px;
}

.hero-statement h1 em {
    font-style: italic;
    color: var(--primary);
    font-weight: 400;
}

.hero-statement p {
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-muted);
    max-width: 620px;
    margin-bottom: 24px;
}

.hero-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

/* Button Utilities */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--primary);
    color: #fff !important;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(27, 59, 90, 0.18);
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(27, 59, 90, 0.25);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--bg-surface);
    color: var(--text-main);
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
    text-decoration: none;
}

.btn-secondary:hover {
    background: var(--bg-subtle);
    border-color: #d8d2c6;
    color: var(--text-main);
}

/* Share Feedback Toast & Share Button */
.share-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(30px);
    background: #1b3b5a;
    color: #ffffff;
    padding: 11px 22px;
    border-radius: var(--radius-full);
    font-size: 13.5px;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(27, 59, 90, 0.28), 0 2px 6px rgba(0, 0, 0, 0.08);
    opacity: 0;
    pointer-events: none;
    transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 99999;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.share-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.btn-share-action {
    transition: var(--transition);
}

.btn-share-action.copied {
    border-color: var(--accent-green) !important;
    color: var(--accent-green) !important;
    background: var(--accent-green-light) !important;
}


.btn-subtle {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.btn-subtle:hover {
    color: var(--primary);
    background: rgba(0, 0, 0, 0.03);
}

/* ==========================================================================
   Blog Posts List & Single Post
   ========================================================================== */

.posts-stream {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.post-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px 36px;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.post-card:hover {
    box-shadow: var(--shadow-md);
    border-color: #ded7ca;
}

.post-header-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
}

.post-date-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.post-tags-list {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-chip {
    font-size: 11px;
    font-weight: 600;
    color: var(--primary);
    background: var(--primary-light);
    padding: 3px 8px;
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.tag-chip:hover {
    background: #dceaf4;
}

.post-title {
    font-family: var(--font-serif);
    font-size: 26px;
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-main);
    margin-bottom: 18px;
    letter-spacing: -0.2px;
}

.post-title a {
    color: var(--text-main);
    text-decoration: none;
    transition: var(--transition);
}

.post-title a:hover {
    color: var(--primary);
}

.post-body {
    font-size: 15px;
    line-height: 1.75;
    color: #2b2926;
}

.post-body p {
    margin-bottom: 16px;
}

.post-body p:last-child {
    margin-bottom: 0;
}

.post-body a {
    color: var(--primary);
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    transition: var(--transition);
}

.post-body a:hover {
    color: var(--primary-hover);
    text-decoration-thickness: 2px;
}

.post-body blockquote {
    margin: 20px 0;
    padding: 12px 20px;
    border-left: 3px solid var(--primary);
    background: var(--primary-light);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-family: var(--font-serif);
    font-size: 17px;
    font-style: italic;
    color: var(--primary);
    line-height: 1.6;
}

.post-body ul, .post-body ol {
    margin: 14px 0 16px 24px;
    line-height: 1.7;
}

.post-body li {
    margin-bottom: 6px;
}

/* Pagination */
.pagination-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 36px;
    border-top: 1px solid var(--border-color);
    margin-top: 20px;
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.pagination-btn:hover {
    background: var(--bg-subtle);
    border-color: #ded7ca;
}

.pagination-info {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

/* ==========================================================================
   Page Containers & Editorial Headings
   ========================================================================== */

.page-header {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.page-category-tag {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 8px;
    display: block;
}

.page-title {
    font-family: var(--font-serif);
    font-size: 34px;
    font-weight: 500;
    line-height: 1.25;
    color: var(--text-main);
    letter-spacing: -0.3px;
    margin-bottom: 12px;
}

.page-intro {
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-muted);
}

.page-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px 36px;
    box-shadow: var(--shadow-sm);
}

/* ==========================================================================
   Form Styles (Scrivimi & Tracking)
   ========================================================================== */

.modern-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.form-group label .required-dot {
    color: var(--accent-stamp);
    font-size: 14px;
    line-height: 1;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 11px 14px;
    font-size: 14px;
    font-family: inherit;
    color: var(--text-main);
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
    box-shadow: var(--shadow-xs);
}

.form-group input:hover,
.form-group textarea:hover {
    border-color: #cfc8ba;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
    line-height: 1.6;
}

.form-grid-row {
    display: grid;
    grid-template-columns: 100px 1fr 90px;
    gap: 12px;
}

.form-hint {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* Success Confirmation Card */
.success-banner {
    background: var(--bg-surface);
    border: 1px solid #c2e2cc;
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.success-banner::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-green);
}

.success-icon-badge {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: var(--accent-green-light);
    color: var(--accent-green);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    box-shadow: 0 4px 12px rgba(45, 106, 79, 0.15);
}

.success-title {
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 600;
    color: var(--accent-green);
    margin-bottom: 8px;
}

.success-desc {
    font-size: 15px;
    color: var(--text-muted);
    max-width: 480px;
    margin: 0 auto 24px auto;
    line-height: 1.6;
}

.tracking-code-showcase {
    background: var(--bg-canvas);
    border: 1px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.tracking-code-val {
    font-family: var(--font-mono);
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: 2px;
}

.btn-copy {
    background: #fff;
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-copy:hover {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--primary);
}

/* ==========================================================================
   Tracking Page (Vertical Journey)
   ========================================================================== */

.tracking-search-bar {
    display: flex;
    gap: 10px;
    margin: 24px 0 32px 0;
}

.tracking-search-input {
    flex: 1;
    padding: 12px 18px;
    font-family: var(--font-mono);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.tracking-search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Calligraphic Tracking Journey Stage */
.tracking-journey-stage {
    max-width: 680px;
    margin: 0 auto;
    position: relative;
    padding-bottom: 24px;
    scroll-margin-top: 30px;
    overflow-x: clip;
    width: 100%;
}

/* SVG Canvas behind milestones but over cards */
.ink-canvas-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
    overflow: visible;
}

/* Travelling Pen Nib Follower */
.pen-nib-follower {
    position: absolute;
    top: 0;
    left: 0;
    width: 28px;
    height: 28px;
    margin-left: -14px;
    margin-top: -14px;
    pointer-events: none;
    z-index: 25;
    opacity: 0;
    transition: opacity 0.25s ease;
    filter: drop-shadow(0 3px 6px rgba(27, 59, 90, 0.3));
}

.pen-nib-follower.drawing {
    opacity: 1;
}

/* Journey Header Card */
.journey-header-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 30px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    position: relative;
    z-index: 10;
    opacity: 0;
    transform: translateY(16px) scale(0.96);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.journey-header-card.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.passport-dest-group .dest-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.passport-dest-group .dest-name {
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 600;
    color: var(--text-main);
    margin: 2px 0;
}

.passport-dest-group .dest-city {
    font-size: 13px;
    color: var(--text-muted);
}

.passport-code-badge {
    text-align: right;
}

.passport-code-badge .code-tag {
    font-family: var(--font-mono);
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--primary);
    background: var(--primary-light);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    border: 1px solid #d4e4f0;
    display: inline-block;
}

.journey-header-main-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.journey-queue-status-note {
    width: 100%;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border-subtle);
    font-family: var(--font-serif);
    font-size: 14px;
    font-style: italic;
    color: var(--text-muted);
    letter-spacing: 0.1px;
    line-height: 1.4;
}

/* Milestones container */
.journey-milestones {
    position: relative;
    padding: 52px 0 42px 0;
    display: flex;
    flex-direction: column;
    gap: 46px;
}

.milestone-item {
    display: flex;
    align-items: center;
    position: relative;
    width: 100%;
    z-index: 6;
    opacity: 0;
    transform: translateY(20px) scale(0.9);
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.milestone-item.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Desktop 2-side layout: Cards stop before central river corridor */
.milestone-item.step-left {
    justify-content: flex-end;
    padding-right: calc(50% + 85px);
    position: relative;
}
.milestone-item.step-left .milestone-node-circle {
    position: absolute;
    right: calc(50% - 26px);
}
.milestone-item.step-left .milestone-card-bubble {
    width: 100%;
    max-width: 220px;
    text-align: right;
    margin-right: 0;
}
.milestone-item.step-left .milestone-top-row {
    justify-content: flex-end;
}

.milestone-item.step-right {
    justify-content: flex-start;
    padding-left: calc(50% + 85px);
    position: relative;
}
.milestone-item.step-right .milestone-node-circle {
    position: absolute;
    left: calc(50% - 26px);
}
.milestone-item.step-right .milestone-card-bubble {
    width: 100%;
    max-width: 220px;
    text-align: left;
    margin-left: 0;
}
.milestone-item.step-right .milestone-top-row {
    justify-content: flex-start;
}

/* Asymmetric river offsets: clear gap between nodes and cards */
#node-1 { transform: translateX(-22px); } /* Left: moderate */
#node-2 { transform: translateX(30px); }  /* Right: wide lazy bend */
#node-3 { transform: translateX(-26px); } /* Left: medium bend */
#node-4 { transform: translateX(18px); }  /* Right: gentle bend */

.milestone-node-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #fff;
    border: 3.5px solid #fff;
    box-shadow: 0 0 0 2px var(--border-color), 0 4px 14px rgba(26, 25, 23, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    flex-shrink: 0;
    z-index: 10;
    transition: all 0.4s ease;
}

.milestone-item.completed .milestone-node-circle {
    background: var(--primary);
    border-color: #fff;
    box-shadow: 0 0 0 2.5px var(--primary), 0 4px 16px rgba(27, 59, 90, 0.35);
    color: #fff;
}

.milestone-item.current .milestone-node-circle {
    background: #fff;
    border-color: #fff;
    box-shadow: 0 0 0 3px var(--primary), 0 0 0 8px var(--primary-light);
    color: var(--primary);
    animation: currentStepPulse 2.2s infinite ease-in-out;
}

.milestone-item.is-last-delivered .milestone-node-circle {
    background: var(--accent-green);
    border-color: #fff;
    box-shadow: 0 0 0 2.5px var(--accent-green), 0 4px 16px rgba(45, 106, 79, 0.35);
    color: #fff;
}

.milestone-item.waiting .milestone-node-circle {
    background: #faf8f5;
    border-color: #fff;
    box-shadow: 0 0 0 2px var(--border-color);
    color: var(--text-light);
}

.milestone-node-circle::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    opacity: 0;
    pointer-events: none;
}

.milestone-item.revealed .milestone-node-circle::after {
    animation: inkRipple 0.8s ease-out forwards;
}

.milestone-item.is-last-delivered.revealed .milestone-node-circle::after {
    border-color: var(--accent-green);
}

@keyframes inkRipple {
    0% { transform: scale(0.85); opacity: 0.85; }
    100% { transform: scale(1.65); opacity: 0; }
}

@keyframes currentStepPulse {
    0%, 100% { box-shadow: 0 0 0 3px var(--primary), 0 0 0 6px rgba(27, 59, 90, 0.12); }
    50% { box-shadow: 0 0 0 3px var(--primary), 0 0 0 10px rgba(27, 59, 90, 0.22); }
}

.milestone-card-bubble {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 10px 14px;
    border-radius: 12px;
    box-shadow: var(--shadow-xs);
    position: relative;
    z-index: 4;
    transition: var(--transition);
}

.milestone-card-bubble:hover {
    box-shadow: var(--shadow-sm);
    border-color: #d6cfc2;
}

.milestone-top-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.milestone-title-text {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-main);
    white-space: nowrap;
}

.milestone-item.completed .milestone-title-text {
    color: var(--primary);
}

.milestone-item.current .milestone-title-text {
    color: var(--primary);
}

.milestone-item.is-last-delivered .milestone-title-text {
    color: var(--accent-green);
}

.milestone-item.waiting .milestone-title-text {
    color: var(--text-light);
}

.milestone-date-chip {
    font-size: 11px;
    font-weight: 700;
    color: var(--primary);
    background: var(--primary-light);
    padding: 3px 8px;
    border-radius: var(--radius-full);
    white-space: nowrap;
    flex-shrink: 0;
}

.milestone-desc-text {
    font-size: 11.5px;
    color: var(--text-muted);
    font-style: italic;
    line-height: 1.35;
}

.milestone-item.waiting .milestone-desc-text {
    color: var(--text-light);
}

/* Feedback card reveal */
.feedback-box-reveal {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 28px;
    box-shadow: var(--shadow-sm);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    z-index: 10;
}

.feedback-box-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.feedback-box-reveal h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 6px;
}

.feedback-box-reveal p {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 14px;
}

/* Replay Bar */
.animation-replay-bar {
    display: flex;
    justify-content: center;
    margin-top: 24px;
    position: relative;
    z-index: 10;
}

.replay-btn {
    background: transparent;
    border: 1px solid var(--border-color);
    padding: 7px 16px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    transition: var(--transition);
}

.replay-btn:hover {
    color: var(--primary);
    border-color: var(--primary);
    background: #fff;
    box-shadow: var(--shadow-xs);
}

.testimonial-display-quote {
    padding: 16px 20px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--primary);
    border-radius: var(--radius-md);
    font-family: var(--font-serif);
    font-size: 16px;
    font-style: italic;
    color: var(--text-main);
    line-height: 1.6;
    margin-top: 10px;
}

/* Mobile responsive view: compact, delicate cards (mobile only), inset safely to avoid edge clipping */
@media (max-width: 600px) {
    .tracking-journey-stage {
        overflow: visible;
    }
    .journey-milestones {
        padding: 32px 12px 26px 12px;
        gap: 30px;
    }
    .milestone-item.step-left,
    .milestone-item.step-right {
        display: flex;
        flex-direction: row;
        justify-content: flex-start;
        align-items: center;
        padding-left: 0;
        padding-right: 0;
        gap: 10px;
        width: 100%;
    }
    .milestone-item.step-left .milestone-node-circle,
    .milestone-item.step-right .milestone-node-circle {
        position: static;
        transform: none !important;
        width: 38px;
        height: 38px;
        border-width: 2.5px;
        flex-shrink: 0;
    }
    .milestone-item.step-left .milestone-card-bubble,
    .milestone-item.step-right .milestone-card-bubble {
        margin-left: 0;
        margin-right: 0;
        flex: 1;
        min-width: 0;
        width: auto;
        max-width: none;
        text-align: left;
        padding: 8px 12px;
        border-radius: 10px;
    }
    .milestone-item.step-left .milestone-top-row,
    .milestone-item.step-right .milestone-top-row {
        justify-content: space-between;
        gap: 6px;
        margin-bottom: 2px;
    }
    .milestone-title-text {
        font-size: 12px;
        font-weight: 700;
        white-space: nowrap;
    }
    .milestone-date-chip {
        font-size: 9.5px;
        padding: 1.5px 6px;
        white-space: nowrap;
    }
    .milestone-desc-text {
        font-size: 11px;
        line-height: 1.35;
    }
    .milestone-node-circle svg {
        width: 15px;
        height: 15px;
    }
    .journey-header-card {
        padding: 16px 18px;
    }
    .journey-queue-status-note {
        margin-top: 10px;
        padding-top: 9px;
        font-size: 12.5px;
        line-height: 1.35;
    }
    .feedback-box-reveal {
        padding: 18px 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .journey-header-card,
    .milestone-item,
    .feedback-box-reveal {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
    .milestone-node-circle::after {
        animation: none !important;
    }
    .pen-nib-follower {
        display: none !important;
    }
}
/* ==========================================================================
   Scheduling Page (Letterflow)
   ========================================================================== */

.letterflow-container {
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin: 32px 0;
    position: relative;
}

.letterflow-step-card {
    display: flex;
    align-items: flex-start;
    gap: 24px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 28px;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.letterflow-step-card:hover {
    border-color: #d6cfc2;
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.letterflow-big-number {
    font-family: var(--font-serif);
    font-size: 46px;
    font-weight: 600;
    color: var(--primary);
    line-height: 1;
    min-width: 70px;
    letter-spacing: -1px;
}

.letterflow-step-body {
    flex: 1;
}

.letterflow-step-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 4px;
}

.letterflow-step-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ==========================================================================
   Site Footer
   ========================================================================== */

.site-footer {
    border-top: 1px solid var(--border-color);
    background: var(--bg-canvas);
    padding: 40px 24px;
    margin-top: auto;
}

.site-footer-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 12px;
    color: var(--text-muted);
}

.footer-quote {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 13px;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 8px 12px;
    align-items: center;
    flex-wrap: wrap;
}

@media (max-width: 600px) {
    .site-footer {
        padding: 28px 16px;
    }
    .site-footer-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 14px;
    }
    .footer-quote {
        text-align: center;
    }
    .footer-links {
        justify-content: center;
        gap: 6px 6px;
    }
    .footer-links .btn-subtle {
        padding: 6px 8px;
        font-size: 12px;
    }
}

/* ==========================================================================
   Admin Dashboard & Post Editor
   ========================================================================== */

.admin-shell {
    max-width: 1140px;
    margin: 0 auto;
    padding: 32px 24px;
}

.admin-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 24px;
}

.admin-tabs {
    display: flex;
    gap: 8px;
    background: var(--bg-subtle);
    padding: 4px;
    border-radius: var(--radius-full);
    margin-bottom: 24px;
    width: fit-content;
}

.admin-tab-btn {
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--radius-full);
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.admin-tab-btn.active {
    background: #fff;
    color: var(--primary);
    box-shadow: var(--shadow-xs);
}

.admin-table-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xs);
    overflow: hidden;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.admin-table th {
    background: #faf7f2;
    padding: 12px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-color);
    text-align: left;
}

.admin-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--border-subtle);
    vertical-align: middle;
}

.admin-table tr:hover td {
    background: #faf9f6;
}

.action-toggle-pill {
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
    background: #fff;
    cursor: pointer;
    transition: var(--transition);
}

.action-toggle-pill.active {
    background: var(--primary-light);
    color: var(--primary);
    border-color: #b6d3e8;
}

.admin-modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(26, 25, 23, 0.45);
    backdrop-filter: blur(4px);
    z-index: 999;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.admin-modal-card {
    background: #fff;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 680px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 32px;
    box-shadow: var(--shadow-lg);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 768px) {
    .site-header {
        position: relative;
        top: auto;
    }

    .site-nav {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-statement h1 {
        font-size: 30px;
    }
    
    .post-card, .page-card, .tracking-journey-timeline {
        padding: 24px 20px;
    }
    
    .form-grid-row {
        grid-template-columns: 1fr;
    }
    
    .letterflow-step-card {
        flex-direction: column;
        gap: 8px;
    }
    
    .letterflow-big-number {
        font-size: 38px;
    }
}


/* Admin Specific Harmonized Components */
.stats-summary {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.stat-card {
    flex: 1;
    min-width: 130px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 14px;
    text-align: center;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.stat-card:hover {
    border-color: #d8d2c6;
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.stat-number {
    font-family: var(--font-serif);
    font-size: 28px;
    font-weight: 600;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-code {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 12px;
    background: var(--primary-light);
    color: var(--primary);
    padding: 3px 8px;
    border-radius: var(--radius-sm);
    border: 1px solid #d4e4f0;
    display: inline-block;
    letter-spacing: 0.5px;
}

.tag-item {
    font-size: 11px;
    font-weight: 600;
    color: var(--primary);
    background: var(--primary-light);
    padding: 2px 7px;
    border-radius: var(--radius-full);
    display: inline-block;
    margin: 1px;
}

.btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #b94a37;
    border: 1px solid #f0cdc8;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.btn-danger:hover {
    background: #b94a37;
    color: #fff;
    border-color: #b94a37;
}

.badge-status-btn {
    border: 1px solid transparent;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    display: inline-block;
    text-align: center;
    transition: var(--transition);
    white-space: nowrap;
    text-transform: lowercase;
}

.badge-status-btn.done {
    background: var(--accent-green-light);
    color: var(--accent-green);
    border-color: #c2e2cc;
}

.badge-status-btn.done:hover {
    background: #ddf0e4;
}

.badge-status-btn.pending {
    background: #f7f5f0;
    color: var(--text-light);
    border-color: var(--border-color);
}

.badge-status-btn.pending:hover {
    background: #eeebe3;
    color: var(--text-main);
}

.filter-input {
    padding: 9px 14px;
    font-size: 13px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: #fff;
    width: 300px;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.filter-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.link-blue {
    color: var(--primary);
    text-decoration: underline;
}

.link-blue:hover {
    color: var(--primary-hover);
}
