/* Eye to Eye Project - Master Stylesheet */

:root {
    --bg-cream: #F5EFE6;
    --page-bg: #FAF6F0;
    --modal-bg: #FBF8F5;
    --text-dark: #352317;
    --text-muted: #6B5546;
    --brand-brown: #975c28;
    --border-subtle: rgba(74, 46, 20, 0.12);
    --shadow-soft: 0 20px 40px rgba(58, 38, 24, 0.08);
    --shadow-deep: 0 30px 60px rgba(0, 0, 0, 0.18);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background-color: var(--bg-cream);
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Accessibility Focus */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
    outline: 2px solid var(--text-dark);
    outline-offset: 2px;
}

/* Header Structure */
header {
    width: 100%;
    max-width: 1400px;
    padding: 1.5rem 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 20;
    animation: fadeInDown 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.header-main-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.brand-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.brand-logo-svg {
    height: 62px;
    width: auto;
}

.header-dedication {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--brand-brown);
    font-style: normal;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-align: center;
    flex: 1;
    padding: 0 1.5rem;
}

.btn-contact {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1.8rem;
    border-radius: 50px;
    border: 1.5px solid var(--text-dark);
    background: transparent;
    color: var(--text-dark);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
    cursor: pointer;
    white-space: nowrap;
}

.btn-contact:hover {
    background-color: var(--text-dark);
    color: var(--bg-cream);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(58, 38, 24, 0.15);
}

/* Main Workspace */
main {
    width: 100%;
    max-width: 1400px;
    padding: 0.5rem 1.5rem 3rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Open Book Workspace (with Hands & Wood Texture) */
.book-wrapper {
    position: relative;
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    container-type: inline-size;
    filter: drop-shadow(0 30px 45px rgba(35, 20, 10, 0.22));
    animation: bookAppear 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.book-bg-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
}

/* Left Page Content */
.page-left {
    position: absolute;
    top: 15.5%;
    left: 13.8%;
    width: 34.2%;
    height: 74%;
    padding: 1% 1.5% 1.5% 1.5%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: var(--text-dark);
    pointer-events: auto;
    overflow: hidden;
}

.letter-content {
    display: flex;
    flex-direction: column;
    gap: 1.1cqw;
    font-size: 1.12cqw;
    line-height: 1.5;
    color: var(--brand-brown);
    font-weight: 400;
}

.letter-greeting {
    font-weight: 700;
    font-size: 1.35cqw;
    margin-bottom: 0.1cqw;
    color: var(--brand-brown);
    opacity: 0;
    animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.4s forwards;
}

.letter-content p:nth-child(2) { opacity: 0; animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.65s forwards; }
.letter-content p:nth-child(3) { opacity: 0; animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.9s forwards; }
.letter-content p:nth-child(4) { opacity: 0; animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 1.15s forwards; }
.letter-content p:nth-child(5) { opacity: 0; animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 1.4s forwards; }

.letter-signoff {
    margin-top: 0.6cqw;
    font-size: 1.12cqw;
    line-height: 1.4;
    opacity: 0;
    animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 1.65s forwards;
}

.letter-signoff strong {
    font-weight: 700;
    color: var(--brand-brown);
}

/* Right Page Content Overlay - Staggered Font Layout */
.page-right {
    position: absolute;
    top: 15.5%;
    right: 10.5%;
    width: 35.5%;
    height: 74%;
    padding: 2% 2%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--brand-brown);
}

.stacked-statement {
    font-family: 'Montserrat', sans-serif;
    font-weight: 900;
    font-size: 3.5cqw;
    line-height: 0.82;
    color: var(--brand-brown);
    margin-bottom: 2.2cqw;
    letter-spacing: -0.04em;
    text-align: center;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stacked-statement span {
    display: block;
    opacity: 0;
    transform: translateY(16px);
    animation: statementWord 1.4s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Precise Staggered Offsets */
.stacked-statement span:nth-child(1) { margin-left: -6%;  animation-delay: 0.4s; }   /* The */
.stacked-statement span:nth-child(2) { margin-left: -4%;  animation-delay: 0.58s; }  /* time */
.stacked-statement span:nth-child(3) { margin-left: -2%;  animation-delay: 0.76s; }  /* has */
.stacked-statement span:nth-child(4) { margin-left: -6%;  animation-delay: 0.94s; }  /* come */
.stacked-statement span:nth-child(5) { margin-left: -2%;  animation-delay: 1.12s; }  /* to */
.stacked-statement span:nth-child(6) { margin-left: -4%;  animation-delay: 1.3s; }   /* acknowledge */
.stacked-statement span:nth-child(7) { margin-left: 0%;   animation-delay: 1.48s; }  /* one */
.stacked-statement span:nth-child(8) { margin-left: -2%;  animation-delay: 1.66s; }  /* another. */

.square-stop {
    display: inline;
    font-size: 0.35em;
    vertical-align: 0.15em;
    margin-left: 0.1em;
}

.right-logo-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4cqw;
    opacity: 0;
    animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 1.85s forwards;
    color: var(--brand-brown);
}

.right-logo-svg {
    width: 8cqw;
    height: auto;
}

.right-page-cta {
    margin-top: 1.5cqw;
    padding: 0.65cqw 1.5cqw;
    border-radius: 50px;
    background: #975c28;
    border: none;
    color: #FFFFFF;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    font-size: 0.85cqw;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    opacity: 0;
    animation: textRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 2.05s forwards;
    box-shadow: 0 4px 14px rgba(151, 92, 40, 0.25);
}

.right-page-cta:hover {
    background: #804d20;
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(151, 92, 40, 0.35);
}

/* Keyframe Animations */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-18px); } to { opacity: 1; transform: translateY(0); } }
@keyframes bookAppear { from { opacity: 0; transform: translateY(30px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes textRise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
@keyframes statementWord { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }

/* Floating Action Widget ("Share your experience") */
.floating-widget-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 90;
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.85rem 1.6rem;
    border-radius: 50px;
    background: #000000;
    color: #FFFFFF;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.3);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    animation: widgetPulse 3.5s ease-in-out infinite;
}

.floating-widget-btn:hover {
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    background: #111111;
}

@keyframes widgetPulse {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* Snapshot Modal Layout */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.25rem;
    overflow-y: auto;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.contact-card {
    background: var(--modal-bg);
    border-radius: 28px;
    max-width: 580px;
    width: 100%;
    padding: 2.75rem 2.25rem;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(0, 0, 0, 0.08);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    text-align: left;
    max-height: 92vh;
    overflow-y: auto;
    color: #111111;
}

.modal-overlay.active .contact-card {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: transparent;
    border: none;
    font-size: 1.4rem;
    color: #111111;
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.close-modal:hover {
    background: rgba(0, 0, 0, 0.06);
}

.modal-header-snapshot {
    text-align: center;
    margin-bottom: 1.5rem;
}

.modal-header-snapshot h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.3rem;
    color: #111111;
    margin-bottom: 0.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.modal-header-snapshot p {
    color: #111111;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.35;
    max-width: 440px;
    margin: 0 auto;
}

.modal-divider {
    width: 100%;
    height: 1px;
    background: rgba(0, 0, 0, 0.1);
    margin: 1.5rem 0;
}

.form-section-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: #111111;
    margin-bottom: 0.85rem;
}

.comfort-options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1.75rem;
}

.comfort-checkbox {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1.1rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.12);
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    color: #111111;
    transition: all 0.2s ease;
    user-select: none;
}

.comfort-checkbox:hover {
    background: #FFFFFF;
    border-color: #111111;
}

.comfort-checkbox input[type="checkbox"] {
    accent-color: #111111;
    width: 18px;
    height: 18px;
    border-radius: 4px;
}

.experience-cards-wrapper {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.exp-card-box {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 18px;
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: all 0.25s ease;
}

.exp-card-box:focus-within, .exp-card-box:hover {
    background: #FFFFFF;
    border-color: rgba(0, 0, 0, 0.25);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.exp-card-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.exp-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #111111;
    color: #FFFFFF;
    font-weight: 800;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.exp-card-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #111111;
    line-height: 1.3;
}

.exp-textarea {
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.9);
    color: #111111;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.92rem;
    outline: none;
    resize: vertical;
    min-height: 85px;
    transition: border-color 0.2s ease;
}

.exp-textarea:focus {
    border-color: #111111;
    background: #FFFFFF;
}

.privacy-email-box {
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 18px;
    padding: 1.1rem 1.2rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.shield-icon-badge {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #111111;
}

.privacy-text-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
}

.privacy-text {
    font-size: 0.82rem;
    color: #444444;
    line-height: 1.4;
    font-weight: 500;
}

.email-input-snapshot {
    width: 100%;
    padding: 0.7rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: #FFFFFF;
    color: #111111;
    font-size: 0.9rem;
    outline: none;
}

.email-input-snapshot:focus {
    border-color: #111111;
}

.submit-btn-snapshot {
    width: 100%;
    padding: 1.1rem;
    border-radius: 50px;
    border: none;
    background: #000000;
    color: #FFFFFF;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}

.submit-btn-snapshot:hover {
    background: #1A1A1A;
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.25);
}

/* Mobile & Tablet Portrait Media Queries (Clean Stacked Cards) */
@media (max-width: 1024px) and (orientation: portrait) {
    header {
        padding: 1.2rem 1.25rem 0.5rem 1.25rem;
        flex-direction: column;
        gap: 0.75rem;
        align-items: center;
    }

    .header-main-row {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .header-dedication {
        font-size: 0.85rem;
        line-height: 1.35;
        width: 100%;
        text-align: center;
        padding: 0.25rem 0;
    }

    .btn-contact {
        padding: 0.5rem 1.2rem;
        font-size: 0.78rem;
    }

    /* Hide background photo image (hands & wood table) on mobile portrait */
    .book-bg-image {
        display: none !important;
    }

    /* Clean Mobile Stacked Layout */
    .book-wrapper {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
        filter: none;
        padding: 0;
    }

    /* Mobile Card - Staggered Headline Page */
    .page-right {
        position: relative;
        top: auto;
        right: auto;
        width: 100%;
        height: auto;
        padding: 2.5rem 1.5rem;
        background: #FDFBF7;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(58, 38, 24, 0.08);
        border: 1px solid rgba(74, 46, 20, 0.1);
        text-align: center;
        order: 1;
    }

    .stacked-statement {
        font-size: 2.2rem;
        line-height: 0.82;
        margin-bottom: 1.75rem;
    }

    .stacked-statement span:nth-child(1) { margin-left: -6%; }
    .stacked-statement span:nth-child(2) { margin-left: -4%; }
    .stacked-statement span:nth-child(3) { margin-left: -2%; }
    .stacked-statement span:nth-child(4) { margin-left: -6%; }
    .stacked-statement span:nth-child(5) { margin-left: -2%; }
    .stacked-statement span:nth-child(6) { margin-left: -4%; }
    .stacked-statement span:nth-child(7) { margin-left: 0%; }
    .stacked-statement span:nth-child(8) { margin-left: -2%; }

    .right-logo-svg {
        width: 80px;
    }

    .right-page-cta {
        margin-top: 1.5rem;
        padding: 0.85rem 1.75rem;
        font-size: 0.92rem;
        white-space: nowrap;
        background: #975c28;
        color: #FFFFFF;
        border-radius: 50px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.4rem;
        max-width: 100%;
        box-shadow: 0 6px 18px rgba(151, 92, 40, 0.25);
    }

    /* Mobile Card - Letter Content Page */
    .page-left {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        height: auto;
        padding: 2.25rem 1.5rem;
        background: #FDFBF7;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(58, 38, 24, 0.08);
        border: 1px solid rgba(74, 46, 20, 0.1);
        overflow: visible;
        order: 2;
    }

    .letter-content {
        font-size: 1rem;
        line-height: 1.6;
        gap: 1.25rem;
    }

    .letter-greeting {
        font-size: 1.3rem;
    }

    .letter-signoff {
        font-size: 1rem;
        margin-top: 0.85rem;
    }
}

/* Horizontal / Landscape Mode on Mobile & Small Screens (Desktop Magazine Spread) */
@media (orientation: landscape) and (max-height: 600px) {
    header {
        padding: 0.6rem 1.5rem;
    }

    .header-dedication {
        font-size: 0.8rem;
    }

    main {
        padding: 0.25rem 1rem 1.5rem 1rem;
    }

    .book-wrapper {
        max-width: 900px;
    }
}

@media (max-width: 480px) and (orientation: portrait) {
    .stacked-statement {
        font-size: 1.85rem;
    }

    .comfort-options-grid {
        grid-template-columns: 1fr;
    }

    .floating-widget-btn span {
        display: inline-block;
    }
}

/* Built By Footer */
.built-by-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 10px 0;
    opacity: 0.4;
    transition: opacity 0.3s ease;
}

.built-by-footer:hover {
    opacity: 0.8;
}

.built-by-footer span {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.55rem;
    font-weight: 500;
    color: #654321;
    letter-spacing: 0.03em;
}

.built-by-footer a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.pws-logo {
    height: 13px;
    width: auto;
    display: block;
}

/* Email Contact Popup */
.email-popup-card {
    background: var(--modal-bg);
    border-radius: 20px;
    padding: 2.5rem 2.5rem 2rem;
    max-width: 360px;
    width: 90%;
    position: relative;
    box-shadow: var(--shadow-deep);
    text-align: center;
    animation: modalSlideUp 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.email-popup-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
}

.email-popup-content h3 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1.3rem;
    color: var(--brand-brown);
    margin: 0.3rem 0 0;
}

.email-popup-content p {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--text-muted);
    margin: 0;
}

.email-link {
    display: inline-block;
    margin-top: 0.5rem;
    padding: 0.7rem 1.5rem;
    background: var(--brand-brown);
    color: #fff;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    border-radius: 50px;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.email-link:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

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