/* Marianne ARG - Letter-style stylesheet */

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #fdfcfa;
    font-family: Georgia, serif;
    color: #4a5a6a;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
    touch-action: manipulation; /* Prevents double-tap zoom but keeps pinch zoom */
}

/* Container */
.container {
    max-width: 720px;
    width: 90%;
    margin: 60px auto 0; /* Added space for fixed banner */
    padding: 16px 20px;
}

/* Typography */
h1 {
    color: #1a4a5e;
    font-size: 3rem;
    font-weight: normal;
    margin-bottom: 1.5rem;
}

.introduction {
    margin-bottom: 1.5rem;
}

.tagline {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.tagline em {
    color: #7b6d8d;
    font-style: italic;
}

.letter-description {
    font-size: 1.05rem;
    color: #4a5a6a;
    margin-bottom: 1rem;
    line-height: 1.5;
}

/* Hidden message that appears when selected */
.hidden-message {
    color: #fdfcfa; /* Same as background - invisible */
    font-size: 1rem;
    line-height: 1.4;
    display: block;
    margin: 0.75rem 0;
    -webkit-user-select: text;
    user-select: text;
    cursor: text;
}

.hidden-message::selection {
    background: #7b6d8d;
    color: #fdfcfa;
}

.hook {
    color: #4a5a6a;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* Spiral emoji animation */
.spiral-trigger {
    display: inline-block;
    cursor: pointer;
    animation: subtle-glow 3s ease-in-out infinite;
    transition: transform 0.3s ease;
}

.spiral-trigger:hover {
    transform: scale(1.2);
    animation-duration: 1.5s;
}

@keyframes subtle-glow {
    0%, 100% {
        filter: brightness(1) drop-shadow(0 0 2px rgba(123, 109, 141, 0.3));
    }
    50% {
        filter: brightness(1.4) drop-shadow(0 0 12px rgba(123, 109, 141, 0.8));
    }
}

/* Form styling */
.contact {
    margin-top: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

input, textarea {
    width: 90%;
    margin-bottom: 0.5rem;
    padding: 0.5rem 0;
    border: none;
    border-bottom: 1px solid #d4d0e0;
    background: transparent;
    font-family: inherit;
    font-size: 1rem;
    color: #4a5a6a;
    transition: border-color 0.3s ease;
    resize: vertical;
}

textarea {
    border: 1px solid #d4d0e0;
    padding: 0.75rem;
    border-radius: 0;
    line-height: 1.5;
}

input:focus, textarea:focus {
    outline: none;
    border-bottom-color: #3498db;
}

textarea:focus {
    border-color: #3498db;
}

input::placeholder, textarea::placeholder {
    color: #9a9aa0;
    font-style: italic;
}

.submit-btn {
    background: transparent;
    color: #3498db;
    border: 1px solid #2a6b7c;
    padding: 0.5rem 1.5rem;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.submit-btn:hover {
    background: #3498db;
    color: #fdfcfa;
}

/* Footer */
.privacy {
    font-size: 0.875rem;
    color: #7a8a9a;
    margin-top: 1.5rem;
    line-height: 1.5;
}

.privacy a {
    color: #7b6d8d;
    text-decoration: underline;
}

/* Accessibility */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Success message */
.protocol-activation-message {
    display: none;
    color: #7b6d8d;
    font-style: italic;
    margin-top: 2rem;
}

.protocol-activation-message.show {
    display: block;
}

.success-actions {
    margin-top: 1.5rem;
    font-size: 0.875rem;
    text-align: center;
}

.success-link {
    color: #7b6d8d;
    text-decoration: none;
    font-style: italic;
    transition: color 0.3s ease;
}

.success-link:hover {
    color: #3498db;
    text-decoration: underline;
}

/* Easter egg hover text styling */
.easter-egg-hover {
    border-bottom: 1px dotted rgba(123, 109, 141, 0.3);
    cursor: help;
    transition: border-color 0.3s ease;
}

.easter-egg-hover:hover {
    border-bottom-color: rgba(123, 109, 141, 0.6);
}

/* Subtle letter texture and waltz background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.02;
    z-index: -1;
    background-image:
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0,0,0,0.03) 2px,
            rgba(0,0,0,0.03) 4px
        );
    pointer-events: none;
}

/* Waltz dance steps background */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    z-index: -2;
    background-image: url('walzvector.png');
    background-size: 300px 300px;
    background-repeat: no-repeat;
    background-position: bottom right;
    pointer-events: none;
}

/* Mobile adjustments */
@media (max-width: 600px) {
    body {
        padding: 1rem;
    }

    /* Hide distracting waltz background on mobile */
    body::after {
        display: none;
    }

    .container {
        width: 95%;
        padding: 16px 8px;
    }
    
    h1 {
        font-size: 3.25rem;
        margin-bottom: 3rem;
    }
    
    .tagline {
        font-size: 1.375rem;
    }
    
    .letter-description {
        font-size: 1.125rem;
    }
    
    .hidden-message {
        font-size: 0.9rem;
        margin: 0.5rem 0;
    }
    
    .hook {
        font-size: 1.25rem;
    }
    
    input, textarea {
        width: 100%;
        font-size: 1rem; /* Prevents zoom on iOS */
    }
    
    textarea {
        min-height: 120px;
    }
    
    .submit-btn {
        width: 100%;
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .introduction {
        margin-bottom: 3rem;
    }
    
    .contact {
        margin-top: 3rem;
    }
}

/* Extra small screens */
@media (max-width: 400px) {
    h1 {
        font-size: 2.75rem;
        margin-bottom: 2rem;
    }
    
    .tagline {
        font-size: 1.25rem;
    }
    
    .letter-description {
        font-size: 1rem;
    }
    
    .hook {
        font-size: 1.125rem;
    }
}

/* Privacy page specific styles */
.privacy-content {
    margin-top: 4rem;
}

.privacy-content h2 {
    color: #1a4a5e;
    font-size: 1.5rem;
    margin-top: 3rem;
    margin-bottom: 1rem;
}

.privacy-content ul {
    margin-left: 2rem;
    margin-bottom: 2rem;
}

.privacy-content li {
    margin-bottom: 0.5rem;
}

.contact-info {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #d4d0e0;
}

.privacy-footer {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #d4d0e0;
}

.privacy-footer a {
    color: #7b6d8d;
    text-decoration: none;
    font-style: italic;
}

.privacy-footer a:hover {
    text-decoration: underline;
}

/* Archive page styles */
.archive-list {
    margin: 2rem 0;
}

.letter-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.letter-list li {
    margin-bottom: 1rem;
    padding-left: 1rem;
    position: relative;
}

.letter-list li::before {
    content: '•';
    color: #7b6d8d;
    position: absolute;
    left: 0;
    top: 0;
}

.letter-list a {
    color: #4a5a6a;
    text-decoration: none;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.letter-list a:hover {
    color: #7b6d8d;
    text-decoration: underline;
}

.archive-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(212, 208, 224, 0.3);
}

.back-link {
    color: #7b6d8d;
    text-decoration: none;
    font-style: italic;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #3498db;
    text-decoration: underline;
}

.archive-link {
    margin-top: 1rem;
    text-align: center;
    font-size: 0.9rem;
}

.archive-link a {
    color: #7b6d8d;
    text-decoration: none;
    font-style: italic;
    transition: color 0.3s ease;
}

.archive-link a:hover {
    color: #3498db;
    text-decoration: underline;
}

/* Archive page unique styling */
.archive-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    min-height: 100vh;
}

.archive-nav {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 3rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(212, 208, 224, 0.3);
}

.home-button {
    color: #7b6d8d;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    font-style: italic;
}

.home-button:hover {
    color: #3498db;
    text-decoration: underline;
}


.archive-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.archive-header h1 {
    font-size: 2.5rem;
    color: #1a4a5e;
    margin-bottom: 0.5rem;
    font-weight: normal;
}

.archive-subtitle {
    color: #8b7d6b;
    font-style: italic;
    font-size: 1.1rem;
    margin: 0;
}

.archive-intro {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.archive-intro p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #4a5a6a;
}

.collection-grid {
    display: grid;
    gap: 2rem;
    margin-bottom: 3rem;
}

.letter-card {
    background: rgba(123, 109, 141, 0.03);
    border: 1px solid rgba(212, 208, 224, 0.4);
    border-radius: 8px;
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
}

.letter-card:hover {
    background: rgba(123, 109, 141, 0.06);
    border-color: rgba(123, 109, 141, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.letter-card h3 {
    margin: 0 0 1rem 0;
    font-size: 1.3rem;
    font-weight: normal;
}

.letter-card h3 a {
    color: #1a4a5e;
    text-decoration: none;
    transition: color 0.3s ease;
}

.letter-card h3 a:hover {
    color: #7b6d8d;
    text-decoration: underline;
}

.letter-excerpt {
    color: #5a5a5a;
    font-size: 1rem;
    line-height: 1.6;
    margin: 0 0 1rem 0;
    font-style: italic;
}

.letter-date {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 0.8rem;
    color: #9a9aa0;
    font-style: italic;
}

.archive-footer {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(212, 208, 224, 0.3);
    margin-top: 3rem;
}


.archive-footer p {
    color: #7a8a9a;
    font-size: 0.95rem;
}

.signup-link {
    color: #7b6d8d;
    text-decoration: none;
    font-style: italic;
    transition: color 0.3s ease;
}

.signup-link:hover {
    color: #3498db;
    text-decoration: underline;
}

/* Mobile adjustments for archive */
@media (max-width: 600px) {
    .archive-container {
        padding: 1.5rem 1rem;
    }

    .archive-header h1 {
        font-size: 2rem;
    }

    .archive-intro p {
        font-size: 1rem;
    }

    .letter-card {
        padding: 1.5rem;
    }

    .letter-card h3 {
        font-size: 1.2rem;
    }

    .letter-date {
        position: static;
        display: block;
        margin-top: 0.5rem;
    }
}

/* Quiz modal styles */
#bm-quiz {
    border: 1px solid #e0d5e7;
    border-radius: 0;
    padding: 24px;
    width: min(720px, 92vw);
    background: #fdfcfa;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

#bm-quiz::backdrop {
    background: rgba(74, 90, 106, 0.3);
}

#bm-quiz header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 20px;
}

#bm-quiz h3 {
    margin: 0 0 8px;
    font-weight: normal;
    color: #1a4a5e;
    font-size: 1.5rem;
    font-family: Georgia, serif;
}

#bm-quiz-sub {
    margin: 0;
    color: #7b6d8d;
    font-style: italic;
    font-size: 0.9rem;
}

#bm-quiz-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #7b6d8d;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

#bm-quiz-close:hover {
    color: #1a4a5e;
}

.bm-q h4 {
    margin: 0 0 16px;
    color: #1a4a5e;
    font-weight: normal;
    font-size: 1.1rem;
    line-height: 1.5;
}

.bm-q label {
    display: block;
    margin: 8px 0;
    color: #4a5a6a;
    cursor: pointer;
    padding: 8px 0;
    transition: color 0.3s ease;
}

.bm-q label:hover {
    color: #3498db;
}

.bm-q input[type="radio"] {
    margin-right: 10px;
    width: auto;
    cursor: pointer;
}

#bm-quiz footer {
    margin-top: 24px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

#bm-quiz button[type="button"] {
    background: transparent;
    color: #3498db;
    border: 1px solid #3498db;
    padding: 8px 20px;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

#bm-quiz button[type="button"]:hover {
    background: #3498db;
    color: #fdfcfa;
}

#bm-quiz-result {
    margin-top: 20px;
    display: none;
}

#bm-quiz-back, #bm-quiz-finish {
    display: none;
}

#bm-result-card {
    border: 1px solid #e0d5e7;
    padding: 20px;
    background: #fafafa;
    margin-bottom: 16px;
}

#bm-role {
    margin: 0 0 12px;
    color: #1a4a5e;
    font-size: 1.3rem;
    font-weight: normal;
}

#bm-brief {
    margin: 0 0 12px;
    color: #4a5a6a;
    line-height: 1.5;
}

#bm-task {
    margin: 0 0 12px;
    font-style: italic;
    color: #7b6d8d;
}

#bm-meta {
    color: #9a9aa0;
    font-size: 0.85rem;
}

#bm-quiz-result div:last-child {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

#bm-mailto {
    color: #7b6d8d;
    text-decoration: underline;
}

#bm-mailto:hover {
    color: #3498db;
}

/* Mobile adjustments for quiz */
@media (max-width: 600px) {
    #bm-quiz {
        padding: 16px;
        width: 100%;
        max-width: 100vw;
    }
    
    #bm-quiz h3 {
        font-size: 1.1rem;
        line-height: 1.4;
    }
    
    .bm-q h4 {
        font-size: 1rem;
    }
    
    .bm-q label {
        font-size: 0.95rem;
        padding: 10px 0;
    }
    
    #bm-quiz footer {
        justify-content: center;
    }
    
    #bm-quiz-result div:last-child {
        justify-content: center;
    }
    
    #bm-quiz input[type="text"],
    #bm-quiz input[type="email"] {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 10px;
    }
    
    #bm-quiz button[type="button"] {
        padding: 12px 20px;
        font-size: 1rem;
    }
}

/* Contingency protocols activated - backup systems operational */
/* Sometimes the most important things are hidden in plain sight */