/* =========================================
   FlowCaptionPro – Global Light Theme
   ========================================= */

/* =========================================
   FlowCaptionPro – Theme Root Variables
   ========================================= */

/* DEFAULT THEME (Blue) – applies when no theme-* class is present */
:root {
    /* Brand colors */
    --brand-primary: #3b82f6;       /* Blue 500 */
    --brand-primary-dark: #1d4ed8;  /* Blue 700 */

    /* Text colors */
    --text-primary: #1e293b;        /* Slate 800 */
    --text-secondary: #475569;      /* Slate 600 */
    --text-muted: #64748b;          /* Slate 500 */

    /* Backgrounds */
    --bg-body: #f8fafc;             /* Light grey */
    --bg-card: #ffffff;             /* White */

    /* Borders */
    --border-light: #e2e8f0;        /* Slate 200 */
}

/* =========================================
   USER-SELECTABLE THEME OVERRIDES
   Each theme uses a body.theme-* class
   ========================================= */

/* BLUE THEME (default SaaS look) */
body.theme-blue {
    --brand-primary: #3b82f6;
    --brand-primary-dark: #1d4ed8;
    --bg-body: #eaf2ff; /* pastel blue */
}

/* MINT THEME (fresh, clean) */
body.theme-mint {
    --brand-primary: #10b981;        /* emerald 500 */
    --brand-primary-dark: #059669;   /* emerald 600 */
    --bg-body: #e9fff7;              /* pastel mint */
}

/* PEACH THEME (warm + friendly) */
body.theme-peach {
    --brand-primary: #f97316;        /* orange 500 */
    --brand-primary-dark: #ea580c;   /* orange 600 */
    --bg-body: #fff4e9;              /* pastel peach */
}

/* PURPLE THEME (creative + bold) */
body.theme-purple {
    --brand-primary: #a855f7;        /* purple 500 */
    --brand-primary-dark: #7e22ce;   /* purple 700 */
    --bg-body: #f3e8ff;              /* pastel lavender */
}

/* Base Page */
body {
    background: var(--bg-body);
    color: var(--text-primary);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
}

/* Lead paragraphs */
.lead {
    color: var(--text-secondary);
}

/* Muted text */
.text-muted {
    color: var(--text-muted) !important;
}

/* NAVBAR */
.navbar {
    background: #ffffff !important;
    border-bottom: 1px solid var(--border-light);
}
.navbar .navbar-brand,
.navbar .nav-link {
    color: var(--text-primary) !important;
}
.navbar .nav-link:hover {
    color: var(--brand-primary) !important;
}

/* Login button (green with black text) */
.btn-login {
    background-color: #4CFF00 !important;
    color: #000 !important;
    border: 1px solid #38cc00 !important;
    font-weight: 600;
}

/* Logout button (red with white text) */
.btn-logout {
    background-color: #ff0000 !important;
    color: #fff !important;
    border: 1px solid #cc0000 !important;
    font-weight: 600;
}

/* Header Logo */
.flowcaption-logo {
    height: 44px;      /* Adjust as preferred */
    width: auto;
    border-radius: 6px; /* optional */
}

.header-logo-right {
    margin-left: auto;
    display: flex;
    align-items: center;
}

.header-logo-right img {
    height: 42px;        /* Adjust size */
    width: auto;
    border-radius: 8px;  /* Optional */
}

/* Layout */
.content-wrapper {
    padding-top: 4rem;
    padding-bottom: 2rem;
}

/* CARDS */
.card {
    background: var(--bg-card);
    color: var(--text-primary);
    border-radius: 1.25rem;
    border: 1px solid var(--border-light) !important;
}
.card .card-title {
    color: var(--text-primary);
}
.card .card-text,
.card p {
    color: var(--text-secondary);
}

/* BUTTONS */
.btn-primary {
    background: var(--brand-primary);
    border-color: var(--brand-primary);
}
.btn-primary:hover {
    background: var(--brand-primary-dark);
    border-color: var(--brand-primary-dark);
}

.btn-outline-dark {
    border-color: var(--text-primary);
    color: var(--text-primary);
}
.btn-outline-dark:hover {
    background: var(--text-primary);
    color: #ffffff;
}

/* User pill in navbar */
.user-pill {
    font-size: 0.85rem;
    color: var(--text-secondary);
}
.badge-admin {
    background-color: var(--brand-primary-dark);
}

/* -----------------------------------------------------------
   ENHANCED HERO SECTION
-------------------------------------------------------------*/

/* Background gradient that shifts based on theme colors */
.hero-section {
    border-radius: 1.5rem;
    background: linear-gradient(
        135deg,
        var(--bg-body) 0%,
        #ffffff 70%
    );
    position: relative;
    overflow: hidden;
}

/* Decorative soft glows */
.hero-section::before,
.hero-section::after {
    content: "";
    position: absolute;
    width: 350px;
    height: 350px;
    background: var(--brand-primary);
    opacity: 0.12;
    filter: blur(120px);
    border-radius: 50%;
    z-index: 0;
}

.hero-section::before {
    top: -80px;
    left: -80px;
}

.hero-section::after {
    bottom: -80px;
    right: -80px;
}

.hero-title,
.hero-subtitle,
.hero-list li,
.hero-card {
    position: relative;
    z-index: 2; /* Above glows */
}

/* Cleaner titles */
.hero-title {
    color: var(--text-primary);
}

.hero-subtitle {
    color: var(--text-secondary);
    max-width: 600px;
}

/* List styling */
.hero-list {
    padding-left: 1.2rem;
    color: var(--text-secondary);
}

.hero-list li {
    margin-bottom: 0.8rem;
}

/* Card consistent with theme */
.hero-card {
    border-radius: 1.25rem;
}

/* Smooth fade-in animation */
.hero-section {
    animation: heroFadeIn 0.6s ease-out both;
}

@keyframes heroFadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Planner grid refinements */
.planner-table {
    font-size: 0.85rem;
}

.planner-post-card {
    border-color: var(--border-light);
}

.planner-post-meta {
    font-weight: 500;
}

.planner-post-time {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 0.75rem;
    opacity: 0.8;
}

.planner-post-platform {
    font-size: 0.8rem;
}

/* Clamp caption to ~3 lines, but allow wrapping */
.planner-caption {
    font-size: 0.8rem;
    white-space: normal;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

/* Tiny hint if hashtags exist */
.planner-hashtags-hint {
    font-size: 0.7rem;
    opacity: 0.7;
}

/* Summary card tweaks */
.planner-summary-card .badge {
    font-size: 0.75rem;
}

/* -----------------------------------------------------------
   PRICING / PLANS
-------------------------------------------------------------*/

.pricing-header h1 {
    color: var(--text-primary);
}

.pricing-header .lead {
    color: var(--text-secondary);
}

/* Generic plan card */
.plan-card {
    transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, border-color 0.15s ease-out;
    border-radius: 1.5rem;
}

.plan-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
}

/* Featured (middle) plan */
.plan-card-featured {
    border-color: var(--brand-primary) !important;
    box-shadow: 0 14px 30px rgba(37, 99, 235, 0.18);
    position: relative;
}
.plan-card-featured::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

/* Small badge at top of card */
.plan-badge {
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Small pill text next to badge */
.plan-pill {
    font-size: 0.8rem;
    font-weight: 500;
}

/* Price styling */
.plan-price-main {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
}

.plan-price-period {
    font-size: 0.9rem;
}

/* Tagline text under plan title */
.plan-tagline {
    font-size: 0.9rem;
}

/* Feature list inside cards */
.plan-feature-list {
    list-style: none;
    padding-left: 0;
    margin-bottom: 1.25rem;
    font-size: 0.9rem;
}

.plan-feature-list li {
    position: relative;
    padding-left: 1.3rem;
    margin-bottom: 0.45rem;
    color: var(--text-secondary);
}

.plan-feature-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 1px;
    font-size: 0.8rem;
    color: var(--brand-primary);
}

/* CTA buttons in pricing cards */
.plan-cta {
    font-weight: 600;
}

/* ============================
   Instagram-style preview card
   ============================ */

.preview-modal-shell {
    border-radius: 1.25rem;
    overflow: hidden;
}

.preview-modal-body {
    background: radial-gradient(circle at top, #0f172a 0, #020617 55%, #020617 100%);
}

/* Card shell */
.ig-preview-card {
    background: #000000;
    color: #f9fafb;
    border-radius: 1.5rem;
    overflow: hidden;
    max-width: 420px;
    border: 1px solid rgba(148, 163, 184, 0.4);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.8);
    font-size: 0.9rem;
}

/* Header (avatar + username + menu) */
.ig-preview-header {
    display: flex;
    align-items: center;
    padding: 0.6rem 0.75rem 0.4rem;
}

.ig-preview-avatar {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: conic-gradient(
        from 160deg,
        #f97316,
        #ec4899,
        #8b5cf6,
        #fbbf24,
        #f97316
    );
    padding: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.5rem;
}

.ig-preview-avatar-inner {
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: #020617;
    border: 1px solid #020617;
}

.ig-preview-user {
    flex: 1;
    min-width: 0;
}

.ig-preview-username {
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.1;
}

.ig-preview-subtitle {
    font-size: 0.7rem;
    color: #9ca3af;
}

.ig-preview-menu {
    font-size: 1.4rem;
    line-height: 1;
    color: #e5e7eb;
    cursor: default;
}

/* Image placeholder */
.ig-preview-image-placeholder {
    position: relative;
    background: #020617;
    aspect-ratio: 4 / 5;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    font-size: 0.75rem;
}

.ig-preview-image-label {
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    border: 1px dashed #4b5563;
    background: rgba(15, 23, 42, 0.8);
}

/* Action buttons row */
.ig-preview-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.45rem 0.75rem 0.25rem;
    font-size: 1.1rem;
}

.ig-preview-actions-left,
.ig-preview-actions-right {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.ig-icon {
    cursor: default;
}

/* Likes line */
.ig-preview-likes {
    padding: 0 0.75rem;
    font-weight: 600;
    font-size: 0.8rem;
}

/* Caption */
.ig-preview-caption {
    padding: 0.25rem 0.75rem 0;
    font-size: 0.82rem;
    line-height: 1.5;
    white-space: pre-wrap;
}

.ig-preview-caption-username {
    font-weight: 600;
    margin-right: 0.25rem;
}

/* Hashtags */
.ig-preview-hashtags {
    padding: 0.15rem 0.75rem 0;
    font-size: 0.8rem;
    color: #9ca3af;
}

/* Comments link */
.ig-preview-comments-link {
    padding: 0.25rem 0.75rem 0;
    font-size: 0.78rem;
    color: #9ca3af;
}

/* Timestamp */
.ig-preview-timestamp {
    padding: 0.4rem 0.75rem 0.75rem;
    font-size: 0.65rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #6b7280;
}

/* Platform-specific theming hook (for later if you add FB/TikTok styles) */
.preview-instagram .ig-preview-card {
    border-color: rgba(244, 114, 182, 0.7);
}

/* =========================================
   Planner – Preview Modal Footer Buttons
   ========================================= */

   .preview-modal-shell .modal-footer {
       background: #020617; /* match dark preview body */
       border-top: 1px solid rgba(148, 163, 184, 0.5);
   }

   .preview-modal-shell .modal-footer .btn {
       border-radius: 999px;
       font-size: 0.8rem;
       padding-inline: 0.9rem;
       padding-block: 0.35rem;
   }

   .preview-modal-shell #previewCopyCaption,
   .preview-modal-shell #previewCopyHashtags,
   .preview-modal-shell #previewCopyAll {
       background-color: transparent;
       color: #e5e7eb;
       border-color: rgba(148, 163, 184, 0.6);
   }

   .preview-modal-shell #previewCopyCaption:hover,
   .preview-modal-shell #previewCopyHashtags:hover,
   .preview-modal-shell #previewCopyAll:hover {
       background-color: rgba(148, 163, 184, 0.1);
       border-color: rgba(148, 163, 184, 0.9);
   }

   .preview-modal-shell #previewPostToSocial {
       background-color: var(--brand-primary);
       border-color: var(--brand-primary);
       color: #0b1120;
       font-weight: 600;
   }

   .preview-modal-shell #previewPostToSocial:disabled {
       opacity: 0.6;
       cursor: not-allowed;
   }

   .preview-modal-shell #previewCopyFeedback {
       font-size: 0.8rem;
   }
   /* -----------------------------------------------------------
    Global Footer – Themed 3-column layout
 ------------------------------------------------------------- */

 /* Wrapper (supports both .site-footer and .wf-footer) */
 .site-footer,
 .wf-footer {
     background: var(--bg-body);
     padding: 40px 20px 24px;
     border-top: 3px solid var(--brand-primary);
     font-size: 15px;
     color: var(--text-primary);
     margin-top: 40px;
 }

 /* Container for the 3 boxes */
 .footer-container,
 .wf-footer-grid {
     display: flex;
     justify-content: space-between;
     gap: 32px;
     flex-wrap: wrap;
     margin-bottom: 24px;
 }

 /* Each box styled as a card */
 .footer-box,
 .wf-footer-box {
     flex: 1;
     min-width: 220px;
     background: var(--bg-card);
     border-radius: 16px;
     border: 1px solid var(--border-light);
     padding: 16px 18px;
     box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06);
 }

 .footer-box h4,
 .wf-footer-box h4 {
     margin-bottom: 10px;
     font-size: 16px;
     font-weight: 600;
     color: var(--text-primary);
 }

 .footer-box p,
 .wf-footer-box p {
     margin: 0;
     line-height: 1.5;
     color: var(--text-secondary);
 }

 .footer-box ul,
 .wf-footer-box ul {
     list-style: none;
     padding: 0;
     margin: 0;
 }

 .footer-box ul li,
 .wf-footer-box ul li {
     margin-bottom: 6px;
 }

 .footer-box a,
 .wf-footer-box a {
     color: var(--text-primary);
     text-decoration: none;
     transition: color 0.15s ease, text-decoration 0.15s ease;
 }

 .footer-box a:hover,
 .wf-footer-box a:hover {
     color: var(--brand-primary);
     text-decoration: underline;
 }

 /* Bottom strip: copyright + WebFootprint link */
 .footer-bottom,
 .wf-footer-bottom {
     border-top: 1px solid var(--border-light);
     padding-top: 12px;
     display: flex;
     flex-wrap: wrap;
     justify-content: space-between;
     gap: 8px;
     font-size: 14px;
     color: var(--text-secondary);
 }

 .footer-bottom a,
 .wf-footer-bottom a {
     color: var(--brand-primary);
     text-decoration: none;
     font-weight: 500;
 }

 .footer-bottom a:hover,
 .wf-footer-bottom a:hover {
     text-decoration: underline;
 }

 /* Mobile responsive */
 @media (max-width: 768px) {
     .footer-container,
     .wf-footer-grid {
         flex-direction: column;
         gap: 20px;
     }

     .footer-bottom,
     .wf-footer-bottom {
         flex-direction: column;
         text-align: center;
     }
 }
