/* Global Styles */
:root {
    --primary-green: #28a745;
    --primary-blue: #4285f4;
    --warning-red: #dc3545;
    --callout-yellow: #fff3cd;
    --border-yellow: #ffc107;
    --text-dark: #2c3e50;
    --text-muted: #6c757d;
    --light-gray: #f8f9fa;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f5f5;
    color: var(--text-dark);
    line-height: 1.6;
}

/* Screen Management */
.screen {
    display: none;
}

.screen.active {
    display: block;
}

/* Logo */
.logo-container {
    display: none;
}

.logo-img {
    width: 100%;
    height: auto;
}

/* Screen 1: Traditional Design */
#screen1 {
    background-color: #f5f5f5;
}

.breaking-headline {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: -0.5px;
    line-height: 1.2;
}

@media (min-width: 768px) {
    .breaking-headline {
        font-size: 2.25rem;
    }
}

/* CSS Check Graphic */
.check-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 0.5rem;
}

.check {
    background: linear-gradient(180deg, #e8f5e8 0%, #d4f1d4 50%, #e8f5e8 100%);
    border: 1px solid #888;
    border-radius: 3px;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
    position: relative;
    font-family: 'Courier New', Courier, monospace;
    aspect-ratio: 2.5 / 1;
    display: flex;
    flex-direction: column;
}

.check-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
    flex-wrap: nowrap;
    gap: 1rem;
}

.check-number-address {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.check-number {
    font-size: 0.7rem;
    color: #666;
    font-weight: normal;
}

.check-address {
    font-size: 0.6rem;
    color: #555;
    line-height: 1.1;
}

.check-bank {
    font-size: 0.95rem;
    font-weight: bold;
    color: #003087;
    text-align: center;
    flex: 1;
    letter-spacing: 0.3px;
}

.check-date {
    font-size: 0.65rem;
    color: #333;
    text-align: right;
    font-weight: normal;
    white-space: nowrap;
}

.check-date span {
    border-bottom: 1px solid #333;
    padding: 0 0.2rem;
    margin-left: 0.2rem;
    font-size: 0.7rem;
}

.check-pay-to {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.6rem;
    align-items: center;
    margin-bottom: 0.35rem;
}

.pay-to-label {
    font-size: 0.55rem;
    color: #666;
    line-height: 1.1;
    white-space: nowrap;
    font-weight: normal;
}

.pay-to-name {
    font-size: 1rem;
    font-weight: bold;
    color: #000;
    border-bottom: 1px solid #666;
    padding: 0.15rem 0;
}

.check-amount-box {
    background-color: #fff;
    border: 1.5px solid #003087;
    padding: 0.3rem 0.5rem;
    font-size: 1.25rem;
    font-weight: bold;
    color: #000;
    border-radius: 2px;
    white-space: nowrap;
}

.check-amount-text {
    border-bottom: 1px solid #666;
    padding: 0.2rem 0;
    margin-bottom: 0.4rem;
    font-size: 0.85rem;
    color: #000;
    font-weight: 600;
}

.dollars-text {
    float: right;
    font-size: 0.65rem;
    color: #666;
    font-weight: normal;
}

.check-memo {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 0.5rem;
    gap: 1rem;
    flex-wrap: nowrap;
}

.memo-section {
    flex: 0 0 auto;
}

.memo-label {
    font-size: 0.55rem;
    color: #666;
    margin-right: 0.4rem;
    font-weight: normal;
}

.memo-text {
    font-size: 0.7rem;
    color: #000;
    border-bottom: 1px solid #666;
    padding: 0 0.3rem;
}

.signature-section {
    text-align: right;
    margin-left: auto;
}

.signature {
    font-family: 'Brush Script MT', cursive;
    font-size: 1.2rem;
    color: #003087;
    margin-bottom: 0.15rem;
}

.signature-label {
    font-size: 0.5rem;
    color: #666;
    border-top: 1px solid #666;
    padding-top: 0.1rem;
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.check-routing {
    font-size: 0.65rem;
    color: #666;
    margin-top: auto;
    padding-top: 0.5rem;
    letter-spacing: 1px;
    text-align: left;
    font-family: 'MICR', 'Courier New', monospace;
}

.check-codes {
    position: absolute;
    bottom: 0.8rem;
    left: 1rem;
    font-size: 0.55rem;
    color: #666;
    line-height: 1.1;
    display: none;
}

/* Responsive check adjustments */
@media (max-width: 768px) {
    .check-container {
        padding: 0.5rem;
    }

    .check {
        padding: 1.25rem;
    }

    .check-number {
        font-size: 0.7rem;
    }

    .check-bank {
        font-size: 0.9rem;
    }

    .check-date {
        font-size: 0.7rem;
    }

    .check-address {
        font-size: 0.65rem;
    }

    .pay-to-label {
        font-size: 0.6rem;
    }

    .pay-to-name {
        font-size: 1.1rem;
    }

    .check-amount-box {
        font-size: 1.3rem;
        padding: 0.4rem 0.6rem;
    }

    .check-amount-text {
        font-size: 0.85rem;
    }

    .memo-label {
        font-size: 0.6rem;
    }

    .memo-text {
        font-size: 0.75rem;
    }

    .signature {
        font-size: 1.3rem;
    }

    .signature-label {
        font-size: 0.6rem;
    }

    .check-routing {
        font-size: 0.75rem;
    }

    .check-codes {
        font-size: 0.6rem;
    }
}

@media (max-width: 576px) {
    .check {
        padding: 0.875rem;
    }

    .check-number {
        font-size: 0.6rem;
    }

    .check-bank {
        font-size: 0.75rem;
    }

    .check-date {
        font-size: 0.6rem;
    }

    .check-address {
        font-size: 0.55rem;
        margin-bottom: 0.75rem;
    }

    .check-pay-to {
        grid-template-columns: auto 1fr;
        gap: 0.5rem;
    }

    .pay-to-label {
        font-size: 0.5rem;
    }

    .pay-to-name {
        font-size: 0.9rem;
        grid-column: 1 / -1;
    }

    .check-amount-box {
        font-size: 1.1rem;
        padding: 0.35rem 0.5rem;
        grid-column: 1 / -1;
        text-align: center;
        margin-top: 0.25rem;
    }

    .check-amount-text {
        font-size: 0.7rem;
        padding: 0.35rem 0;
    }

    .dollars-text {
        font-size: 0.65rem;
    }

    .check-memo {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }

    .memo-label {
        font-size: 0.5rem;
    }

    .memo-text {
        font-size: 0.65rem;
    }

    .signature-section {
        text-align: left;
    }

    .signature {
        font-size: 1.1rem;
    }

    .signature-label {
        font-size: 0.55rem;
    }

    .check-routing {
        font-size: 0.6rem;
        letter-spacing: 1px;
        margin-top: 0.5rem;
    }

    .check-codes {
        font-size: 0.55rem;
        bottom: 1rem;
        left: 1rem;
    }
}

@media (max-width: 400px) {
    .check {
        padding: 0.75rem;
    }

    .check-bank {
        font-size: 0.65rem;
    }

    .pay-to-name {
        font-size: 0.8rem;
    }

    .check-amount-box {
        font-size: 1rem;
    }

    .check-amount-text {
        font-size: 0.6rem;
    }

    .signature {
        font-size: 1rem;
    }

    .check-routing {
        font-size: 0.55rem;
        letter-spacing: 0.5px;
    }
}

/* Callout Box */
.callout-box {
    background-color: var(--callout-yellow);
    border: 2px solid var(--border-yellow);
    border-radius: 8px;
    padding: 1.5rem;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.callout-title {
    color: var(--warning-red);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.callout-text {
    color: var(--text-dark);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 0;
}

/* Main Description */
.main-description {
    max-width: 600px;
    margin: 0 auto;
}

.lead-text {
    font-size: 1.1rem;
    color: var(--text-dark);
    line-height: 1.7;
}

/* CTA Text */
.cta-text {
    max-width: 600px;
    margin: 0 auto;
}

.cta-main {
    font-size: 1.15rem;
    color: var(--text-dark);
}

/* Age Selection */
.age-selection {
    max-width: 500px;
    margin: 0 auto;
}

.age-question {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
}

.btn-age {
    background-color: var(--primary-green);
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    border: none;
    border-radius: 8px;
    padding: 1.25rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3);
}

.btn-age:hover {
    background-color: #218838;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(40, 167, 69, 0.4);
}

.btn-age:active {
    transform: translateY(0);
}

/* Screen 2: Chat Interface */
#screen2 {
    background-color: white;
    min-height: 100vh;
}

/* Warning Banner */
.warning-banner {
    background-color: #fff3cd;
    border-bottom: 2px solid var(--border-yellow);
}

.warning-label {
    color: var(--warning-red);
    font-weight: 700;
}

.warning-banner p {
    color: var(--text-dark);
    font-size: 0.95rem;
}

/* Chat Main */
.chat-main {
    padding: 2rem 1rem;
}

.chat-headline {
    font-size: 1.5rem;
    font-weight: 700;
    color: #4a5568;
    line-height: 1.3;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .chat-headline {
        font-size: 1.75rem;
    }
}

/* Online Status */
.online-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    background-color: #10b981;
    border-radius: 50%;
    display: inline-block;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.status-text {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Chat Container */
.chat-container {
    background-color: white;
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 2rem;
}

.chat-messages {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Chat Message Bubbles */
.message {
    display: flex;
    gap: 0.75rem;
    animation: fadeInUp 0.4s ease;
}

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

.message.agent {
    flex-direction: row;
}

.message.user {
    flex-direction: row-reverse;
    justify-content: flex-start;
}

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.25rem;
}

.message-bubble {
    max-width: 75%;
    padding: 0.875rem 1.125rem;
    border-radius: 18px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.message.agent .message-bubble {
    background-color: #e5e7eb;
    color: var(--text-dark);
    border-bottom-left-radius: 4px;
}

.message.user .message-bubble {
    background-color: var(--primary-blue);
    color: white;
    border-bottom-right-radius: 4px;
}

/* Age Buttons in Chat */
.chat-age-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.btn-chat-age {
    background-color: var(--primary-blue);
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: 25px;
    padding: 0.875rem 1.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.3);
    min-width: 140px;
}

.btn-chat-age:hover {
    background-color: #3367d6;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.4);
}

.btn-chat-age:active {
    transform: translateY(0);
}

/* Yes Button */
.btn-yes {
    background-color: var(--primary-blue);
    color: white;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    padding: 0.75rem 2rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.3);
    align-self: flex-end;
    margin-top: 0.5rem;
}

.btn-yes:hover {
    background-color: #3367d6;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.4);
}

/* Footer */
footer {
    background-color: transparent;
}

/* Utility Classes */
.d-none {
    display: none !important;
}

.text-center {
    text-align: center;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .message-bubble {
        max-width: 85%;
    }

    .chat-headline {
        font-size: 1.25rem;
    }

    .breaking-headline {
        font-size: 1.5rem;
    }
}
