/* ===================================
   Chester A. Arthur Book Website
   Styles by O.H. Preis
   =================================== */

/* CSS Variables - Color Palette inspired by the book cover */
:root {
    --color-gold: #c9a227;
    --color-gold-light: #e8d284;
    --color-gold-dark: #8b6914;
    --color-sepia: #d4a574;
    --color-sepia-light: #f5e6d3;
    --color-sepia-dark: #8b5a2b;
    --color-navy: #1a2a3a;
    --color-navy-light: #2c3e50;
    --color-charcoal: #2d2d2d;
    --color-cream: #faf8f5;
    --color-white: #ffffff;
    --color-black: #1a1a1a;
    
    --font-heading: 'Cinzel', serif;
    --font-body: 'Lora', serif;
    
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.15);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.25);
    --shadow-dramatic: 0 15px 50px rgba(0, 0, 0, 0.4);
    
    --transition-smooth: all 0.3s ease;
    --transition-slow: all 0.5s ease;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 18px;
    line-height: 1.7;
    color: var(--color-charcoal);
    background-color: var(--color-cream);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--color-gold-dark);
    text-decoration: none;
    transition: var(--transition-smooth);
}

a:hover {
    color: var(--color-gold);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.3;
    color: var(--color-navy);
}

/* ===================================
   Header & Navigation
   =================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(to bottom, rgba(26, 42, 58, 0.95), rgba(26, 42, 58, 0.85));
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    transition: var(--transition-smooth);
}

.site-header.scrolled {
    background: rgba(26, 42, 58, 0.98);
    padding: 0.75rem 2rem;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--color-gold);
    letter-spacing: 2px;
}

.nav-logo:hover {
    color: var(--color-gold-light);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-links a {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--color-cream);
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.5rem 0;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-gold);
    transition: var(--transition-smooth);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--color-gold);
}

/* Mobile Navigation Toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--color-cream);
    transition: var(--transition-smooth);
}

/* ===================================
   Hero Section
   =================================== */
.hero {
    position: relative;
    width: 100%;
    height: 70vh;
    min-height: 500px;
    max-height: 800px;
    overflow: hidden;
}

.hero-image-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    /* This crops the bottom of the image, hiding the author name */
}

.hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, var(--color-cream) 0%, transparent 100%);
    pointer-events: none;
}

/* ===================================
   Book Title Section
   =================================== */
.book-title-section {
    text-align: center;
    padding: 3rem 2rem 4rem;
    background: var(--color-cream);
    position: relative;
    margin-top: -5rem;
}

.book-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    color: var(--color-navy);
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.book-subtitle {
    font-family: var(--font-heading);
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: var(--color-gold-dark);
    font-style: italic;
    font-weight: 400;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

.book-author {
    font-size: 1.1rem;
    color: var(--color-charcoal);
    margin-bottom: 0.5rem;
}

.book-coming {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: var(--color-gold);
    text-transform: uppercase;
    letter-spacing: 3px;
}

/* ===================================
   Feature Tiles
   =================================== */
.tiles-section {
    padding: 2rem 2rem 5rem;
    background: var(--color-cream);
}

.tiles-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: -2rem;
}

.tile {
    background: var(--color-white);
    border-radius: 8px;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: var(--transition-smooth);
    border: 1px solid rgba(201, 162, 39, 0.2);
    display: block;
}

.tile:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-dramatic);
    border-color: var(--color-gold);
}

.tile-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.tile-title {
    font-size: 1.3rem;
    color: var(--color-navy);
    margin-bottom: 0.75rem;
    letter-spacing: 1px;
}

.tile-description {
    font-size: 1rem;
    color: var(--color-charcoal);
    line-height: 1.6;
}

.tile:hover .tile-title {
    color: var(--color-gold-dark);
}

/* ===================================
   Teaser Section
   =================================== */
.teaser-section {
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    padding: 5rem 2rem;
    text-align: center;
}

.teaser-content {
    max-width: 800px;
    margin: 0 auto;
}

.teaser-content h2 {
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    color: var(--color-gold);
    margin-bottom: 1.5rem;
    letter-spacing: 2px;
}

.teaser-content p {
    font-size: 1.15rem;
    color: var(--color-sepia-light);
    line-height: 1.8;
    margin-bottom: 2rem;
}

/* ===================================
   Buttons
   =================================== */
.btn {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.95rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 1rem 2.5rem;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition-smooth);
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--color-gold);
    color: var(--color-navy);
    border-color: var(--color-gold);
}

.btn-primary:hover {
    background: var(--color-gold-light);
    color: var(--color-navy);
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

.btn-secondary {
    background: var(--color-navy);
    color: var(--color-gold);
    border-color: var(--color-navy);
}

.btn-secondary:hover {
    background: var(--color-navy-light);
    color: var(--color-gold-light);
}

.btn-outline {
    background: transparent;
    color: var(--color-gold);
    border-color: var(--color-gold);
}

.btn-outline:hover {
    background: var(--color-gold);
    color: var(--color-navy);
}

.btn-large {
    padding: 1.25rem 3rem;
    font-size: 1rem;
}

/* ===================================
   Page Header (About & Signup)
   =================================== */
.page-header {
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    padding: 8rem 2rem 4rem;
    text-align: center;
}

.page-header h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    color: var(--color-gold);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.page-header p {
    color: var(--color-sepia-light);
    font-size: 1.1rem;
    margin-top: 1rem;
}

/* ===================================
   Content Sections
   =================================== */
.content-section {
    padding: 5rem 2rem;
    background: var(--color-cream);
}

.content-container {
    max-width: 1000px;
    margin: 0 auto;
}

.book-info {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 3rem;
    align-items: start;
}

.book-cover-small {
    position: sticky;
    top: 100px;
}

.book-cover-small img {
    border-radius: 4px;
    box-shadow: var(--shadow-dramatic);
}

.book-synopsis h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--color-navy);
}

.book-synopsis p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

/* ===================================
   Chapter Section
   =================================== */
.chapter-section {
    padding: 5rem 2rem;
    background: var(--color-white);
}

.chapter-section h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    color: var(--color-navy);
    text-align: center;
}

.chapter-preview {
    max-width: 750px;
    margin: 0 auto;
    padding: 2rem;
    background: var(--color-sepia-light);
    border-radius: 8px;
    border-left: 4px solid var(--color-gold);
}

.chapter-opening {
    font-size: 1.1rem;
}

.drop-cap {
    float: left;
    font-family: var(--font-heading);
    font-size: 4rem;
    line-height: 0.8;
    padding-right: 0.5rem;
    color: var(--color-gold-dark);
}

.chapter-preview p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.chapter-quote {
    font-style: italic;
    font-size: 1.15rem;
    color: var(--color-navy);
    border-left: 3px solid var(--color-gold);
    margin: 0 0 2rem 0;
    padding: 1.25rem 1.5rem;
    background: rgba(201, 162, 39, 0.08);
    border-radius: 0 4px 4px 0;
}

.chapter-quote p {
    margin-bottom: 0.75rem;
    text-align: left;
}

.chapter-quote cite {
    display: block;
    font-style: normal;
    font-size: 0.9rem;
    color: var(--color-sepia-dark);
    margin-top: 0.5rem;
}

.chapter-continue {
    text-align: center;
    font-style: italic;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-sepia);
}

.chapter-continue a {
    color: var(--color-gold-dark);
    font-weight: 500;
}

.chapter-footnote {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-sepia);
    text-align: center;
}

.chapter-footnote p {
    font-size: 0.9rem;
    color: var(--color-sepia-dark);
    margin-bottom: 0;
    text-align: center;
}

/* ===================================
   Author Section
   =================================== */
.author-section {
    padding: 5rem 2rem;
    background: var(--color-cream);
}

.author-section h2 {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    text-align: center;
}

.author-content {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 3rem;
    align-items: start;
}

.author-photo-placeholder {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gold);
    font-family: var(--font-heading);
    font-size: 1.2rem;
    letter-spacing: 1px;
}

.author-bio p {
    margin-bottom: 1.5rem;
}

/* ===================================
   CTA Section
   =================================== */
.cta-section {
    padding: 5rem 2rem;
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    text-align: center;
}

.cta-section h2 {
    color: var(--color-gold);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.cta-section p {
    color: var(--color-sepia-light);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* ===================================
   Signup Section
   =================================== */
.signup-section {
    padding: 5rem 2rem;
    background: var(--color-cream);
}

.signup-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.signup-info h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
}

.signup-benefits {
    list-style: none;
    margin: 1.5rem 0;
}

.signup-benefits li {
    padding: 0.75rem 0;
    font-size: 1.05rem;
}

.signup-promise {
    font-size: 0.9rem;
    color: #666;
    font-style: italic;
    margin-top: 1.5rem;
}

.signup-form-container {
    background: var(--color-white);
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(201, 162, 39, 0.2);
}

.signup-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    letter-spacing: 1px;
    color: var(--color-navy);
}

.form-group input[type="text"],
.form-group input[type="email"] {
    padding: 1rem;
    font-family: var(--font-body);
    font-size: 1rem;
    border: 2px solid #ddd;
    border-radius: 4px;
    transition: var(--transition-smooth);
}

.form-group input:focus {
    outline: none;
    border-color: var(--color-gold);
    box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.2);
}

.form-group-checkbox {
    flex-direction: row;
    align-items: flex-start;
    gap: 0.75rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.95rem;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 0.25rem;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.btn-submit {
    margin-top: 1rem;
    width: 100%;
}

.hidden {
    display: none !important;
}

/* ===================================
   Preview Section
   =================================== */
.preview-section {
    padding: 5rem 2rem;
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    text-align: center;
}

.preview-content h2 {
    color: var(--color-gold);
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.preview-content p {
    color: var(--color-sepia-light);
    margin-bottom: 2rem;
}

.preview-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===================================
   Success Page
   =================================== */
.success-section {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8rem 2rem 4rem;
    background: var(--color-cream);
}

.success-content {
    text-align: center;
    max-width: 600px;
}

.success-icon {
    width: 100px;
    height: 100px;
    background: var(--color-gold);
    color: var(--color-navy);
    font-size: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
}

.success-content h1 {
    font-size: 2.5rem;
    color: var(--color-navy);
    margin-bottom: 1rem;
}

.success-message {
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.success-content p {
    margin-bottom: 2rem;
}

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===================================
   Footer
   =================================== */
.site-footer {
    background: var(--color-navy);
    padding: 3rem 2rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 2rem;
    align-items: center;
}

.footer-info {
    text-align: left;
}

.footer-title {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--color-gold);
    letter-spacing: 1px;
}

.footer-author {
    font-size: 0.9rem;
    color: var(--color-sepia-light);
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--color-cream);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-links a:hover {
    color: var(--color-gold);
}

.footer-copyright {
    text-align: right;
}

.footer-copyright p {
    font-size: 0.85rem;
    color: var(--color-sepia);
}

/* ===================================
   Mobile Responsive
   =================================== */
@media (max-width: 900px) {
    .book-info {
        grid-template-columns: 1fr;
    }
    
    .book-cover-small {
        position: static;
        max-width: 250px;
        margin: 0 auto 2rem;
    }
    
    .author-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .author-photo-placeholder {
        margin: 0 auto;
    }
    
    .signup-container {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1.5rem;
    }
    
    .footer-info, .footer-copyright {
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--color-navy);
        flex-direction: column;
        padding: 1rem 2rem;
        gap: 0;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-links li {
        padding: 1rem 0;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero {
        height: 50vh;
        min-height: 350px;
    }
    
    .tiles-container {
        grid-template-columns: 1fr;
    }
    
    .preview-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .preview-buttons .btn {
        width: 100%;
        max-width: 280px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }
    
    .site-header {
        padding: 0.75rem 1rem;
    }
    
    .book-title-section {
        padding: 2rem 1rem 3rem;
    }
    
    .tile {
        padding: 2rem 1.5rem;
    }
    
    .signup-form-container {
        padding: 1.5rem;
    }
    
    .chapter-preview {
        padding: 1.5rem;
    }
}

/* ===================================
   Cookie Consent Banner
   =================================== */

.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--color-navy) 0%, var(--color-navy-light) 100%);
    color: var(--color-white);
    padding: 1.5rem;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    border-top: 3px solid var(--color-gold);
}

.cookie-consent-banner.show {
    transform: translateY(0);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
}

.cookie-consent-text {
    margin-bottom: 1.5rem;
}

.cookie-consent-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--color-gold);
}

.cookie-consent-text p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 0.75rem;
    color: var(--color-sepia-light);
}

.cookie-consent-links {
    margin-top: 0.5rem;
}

.cookie-link {
    color: var(--color-gold-light);
    text-decoration: underline;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.cookie-link:hover {
    color: var(--color-gold);
}

.cookie-consent-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.btn-consent {
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-family: var(--font-body);
    font-weight: 500;
}

.btn-consent.btn-primary {
    background: var(--color-gold);
    color: var(--color-navy);
}

.btn-consent.btn-primary:hover {
    background: var(--color-gold-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(201, 162, 39, 0.3);
}

.btn-consent.btn-secondary {
    background: transparent;
    color: var(--color-white);
    border: 2px solid var(--color-sepia);
}

.btn-consent.btn-secondary:hover {
    background: var(--color-sepia);
    border-color: var(--color-sepia-light);
}

/* Cookie Settings Panel */
.cookie-settings {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cookie-category {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cookie-category:last-of-type {
    border-bottom: none;
    margin-bottom: 1rem;
}

.cookie-category-header {
    margin-bottom: 0.5rem;
}

.cookie-category-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 1rem;
}

.cookie-category-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--color-gold);
}

.cookie-category-label input[type="checkbox"]:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.cookie-category-description {
    font-size: 0.85rem;
    color: var(--color-sepia-light);
    line-height: 1.5;
    margin-left: 2rem;
    margin-top: 0.5rem;
}

.cookie-settings-actions {
    margin-top: 1rem;
    padding-top: 1rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cookie-consent-banner {
        padding: 1rem;
    }

    .cookie-consent-title {
        font-size: 1.25rem;
    }

    .cookie-consent-text p {
        font-size: 0.9rem;
    }

    .cookie-consent-actions {
        flex-direction: column;
    }

    .btn-consent {
        width: 100%;
        text-align: center;
    }

    .cookie-settings {
        padding: 1rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .cookie-consent-banner {
        transition: none;
    }

    .btn-consent:hover {
        transform: none;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .cookie-consent-banner {
        border-top: 5px solid var(--color-gold);
    }

    .btn-consent.btn-secondary {
        border-width: 3px;
    }
}

