/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background-color: #ffffff;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.2;
    margin-bottom: 1rem;
    font-weight: 600;
}

h1 {
    font-size: 2.5rem;
    color: #1a365d;
}

h2 {
    font-size: 2rem;
    color: #2d3748;
}

h3 {
    font-size: 1.5rem;
    color: #2d3748;
}

p {
    margin-bottom: 1rem;
    color: #4a5568;
}

a {
    color: #3182ce;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #2c5aa0;
    text-decoration: underline;
}

a:focus {
    outline: 2px solid #3182ce;
    outline-offset: 2px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1.2;
}

.btn:focus {
    outline: 2px solid #3182ce;
    outline-offset: 2px;
}

.btn-primary {
    background-color: #3182ce;
    color: white;
}

.btn-primary:hover {
    background-color: #2c5aa0;
    text-decoration: none;
    color: white;
}

.btn-secondary {
    background-color: #e2e8f0;
    color: #2d3748;
    border: 1px solid #cbd5e0;
}

.btn-secondary:hover {
    background-color: #cbd5e0;
    text-decoration: none;
    color: #2d3748;
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.125rem;
}

.btn-link {
    background: none;
    color: #3182ce;
    padding: 8px 16px;
    text-decoration: underline;
}

.btn-link:hover {
    color: #2c5aa0;
}

/* Header */
.header {
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.nav-brand a {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a365d;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: #4a5568;
    font-weight: 500;
    padding: 0.5rem 0;
}

.nav-menu a:hover,
.nav-menu a[aria-current="page"] {
    color: #3182ce;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.hero h1 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 3rem;
}

.hero-subtext {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.trust-strip {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    opacity: 0.9;
}

.trust-items {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.trust-logo {
    display: flex;
    align-items: center;
}

.gamble-aware-logo {
    height: 40px;
    width: auto;
    transition: opacity 0.2s ease;
}

.gamble-aware-logo:hover {
    opacity: 0.8;
}

.trust-strip span {
    position: relative;
}

.trust-items span:not(:last-child)::after {
    content: "•";
    position: absolute;
    right: -1rem;
    color: rgba(255, 255, 255, 0.6);
}

/* How We Help Section */
.how-we-help {
    padding: 4rem 0;
    background-color: #f7fafc;
}

.how-we-help h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.help-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.help-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.help-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.help-card h3 {
    color: #3182ce;
    margin-bottom: 1rem;
}

/* Immediate Help Section */
.immediate-help {
    padding: 3rem 0;
    background-color: #fff5f5;
}

.urgent-help-box {
    background: white;
    padding: 2.5rem;
    border-radius: 8px;
    border-left: 4px solid #e53e3e;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.urgent-help-box h2 {
    color: #e53e3e;
    margin-bottom: 1.5rem;
}

.urgent-contacts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.urgent-contact {
    text-align: center;
    padding: 1.5rem;
    background-color: #f7fafc;
    border-radius: 6px;
}

.urgent-contact strong {
    display: block;
    margin-bottom: 0.5rem;
    color: #2d3748;
}

.urgent-contact a {
    font-size: 1.25rem;
    font-weight: 600;
    color: #e53e3e;
    display: block;
    margin-bottom: 0.5rem;
}

.urgent-contact small {
    display: block;
    color: #718096;
}

.urgent-note {
    text-align: center;
    font-size: 0.9rem;
    color: #718096;
}

/* Approach Section */
.approach {
    padding: 4rem 0;
}

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

.approach-methods {
    display: grid;
    gap: 2rem;
    margin: 2rem 0;
}

.method {
    padding: 1.5rem;
    background-color: #f7fafc;
    border-radius: 6px;
    border-left: 4px solid #3182ce;
}

.method h3 {
    color: #3182ce;
    margin-bottom: 0.5rem;
}

.disclaimer {
    background-color: #fff5f5;
    padding: 1.5rem;
    border-radius: 6px;
    border-left: 4px solid #f56565;
    margin-top: 2rem;
}

.disclaimer p {
    margin: 0;
    font-size: 0.9rem;
    color: #742a2a;
}

/* Get Support Section */
.get-support {
    padding: 4rem 0;
    background-color: #f7fafc;
}

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

.contact-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.contact-method {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.contact-method h3 {
    margin-bottom: 1rem;
    color: #2d3748;
}

.contact-form-section {
    background: white;
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.form-note {
    font-size: 0.9rem;
    color: #718096;
    margin-bottom: 2rem;
    font-style: italic;
}

/* Form Styles */
.contact-form {
    display: grid;
    gap: 1.5rem;
}

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

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #2d3748;
}

.form-group input,
.form-group select {
    padding: 12px;
    border: 1px solid #cbd5e0;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #3182ce;
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.1);
}

.checkbox-group {
    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.9rem;
    line-height: 1.4;
}

.checkbox-label input[type="checkbox"] {
    margin: 0;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.error-message {
    color: #e53e3e;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
}

.error-message.show {
    display: block;
}

/* Form validation states */
input[aria-invalid="true"] {
    border-color: #e53e3e;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}

input:valid {
    border-color: #38a169;
}

/* Accessibility Statement */
.accessibility-statement {
    padding: 3rem 0;
    background-color: #f7fafc;
}

.accessibility-statement h2 {
    margin-bottom: 1.5rem;
    color: #2d3748;
}

.accessibility-statement h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #4a5568;
}

.accessibility-statement p {
    margin-bottom: 1rem;
    line-height: 1.6;
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #2d3748;
    color: white;
    padding: 1rem;
    z-index: 1000;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.2);
    display: none;
}

.cookie-banner.show {
    display: block;
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.cookie-content h3 {
    color: white;
    margin: 0 0 0.5rem 0;
    font-size: 1.125rem;
}

.cookie-content p {
    margin: 0;
    color: #e2e8f0;
    font-size: 0.9rem;
}

.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cookie-buttons .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* Cookie Modal */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.5);
    z-index: 1001;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.cookie-modal.show {
    display: flex;
}

.cookie-modal-content {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
}

.cookie-category {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

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

.cookie-category div {
    flex: 1;
}

.cookie-category h4 {
    margin: 0 0 0.5rem 0;
    color: #2d3748;
}

.cookie-category p {
    margin: 0;
    font-size: 0.9rem;
    color: #718096;
}

.toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
    margin-left: 1rem;
}

.toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e0;
    transition: 0.2s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.2s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #3182ce;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

input:disabled + .slider {
    opacity: 0.5;
    cursor: not-allowed;
}

.cookie-modal-buttons {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
}

/* Page Header */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    color: white;
    margin-bottom: 1rem;
}

.page-header p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.125rem;
}

/* Resources Grid */
.resources-grid {
    padding: 4rem 0;
}

.resource-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.resource-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.resource-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.resource-card.featured {
    border-top: 4px solid #3182ce;
}

.resource-card h2 {
    color: #3182ce;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.resource-number {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.resource-number a {
    color: #e53e3e;
    text-decoration: none;
}

.emergency-section {
    background-color: #fff5f5;
    padding: 2.5rem;
    border-radius: 8px;
    border-left: 4px solid #e53e3e;
}

.emergency-section h2 {
    color: #e53e3e;
    text-align: center;
    margin-bottom: 2rem;
}

.emergency-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.emergency-card {
    background: white;
    padding: 2rem;
    border-radius: 6px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.emergency-card h3 {
    color: #2d3748;
    margin-bottom: 1rem;
}

.emergency-number {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.emergency-number a {
    color: #e53e3e;
    text-decoration: none;
}

/* Privacy Content */
.privacy-content {
    padding: 3rem 0;
}

.privacy-text {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

.privacy-text h2 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    color: #2d3748;
}

.privacy-text h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #4a5568;
}

.privacy-text ul {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.privacy-text li {
    margin-bottom: 0.5rem;
    color: #4a5568;
}

/* Footer */
.footer {
    background-color: #2d3748;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1rem;
}

.footer-section p {
    margin-bottom: 1rem;
    color: white;
}

.footer-section address {
    font-style: normal;
    line-height: 1.6;
    color: white !important;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
    color: white !important;
}

.footer-section a {
    color: white !important;
    text-decoration: none;
}

.footer-section a:hover {
    color: white !important;
    text-decoration: underline;
}

.footer-bottom {
    border-top: 1px solid #4a5568;
    padding-top: 2rem;
    text-align: center;
    color: white !important;
}

.footer-bottom .disclaimer {
    background-color: #1a202c;
    padding: 1.5rem;
    border-radius: 6px;
    margin-bottom: 1rem;
}

.footer-bottom .disclaimer p {
    margin: 0;
    font-size: 0.9rem;
    color: white !important;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: white !important;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: white !important;
    text-decoration: underline;
}

.copyright {
    color: #ffffff !important;
    font-size: 0.9rem;
    margin: 0;
}

/* Age Verification Modal */
.age-verification-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.9);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.age-verification-modal.show {
    display: flex;
}

.age-verification-content {
    background: white;
    padding: 3rem;
    border-radius: 8px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.age-verification-content h2 {
    color: #1a365d;
    margin-bottom: 1.5rem;
}

.age-verification-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.age-verification-footer {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
    text-align: left;
}

.age-verification-footer p {
    font-size: 0.9rem;
    color: #4a5568;
    margin-bottom: 1rem;
}

.age-verification-footer ul {
    list-style: none;
    padding: 0;
}

.age-verification-footer li {
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.age-verification-footer a {
    color: #3182ce;
    font-weight: 500;
}

/* Under 18 Page */
.under-18-page {
    min-height: 100vh;
    background-color: #f7fafc;
    padding: 2rem 0;
}

.under-18-content {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 3rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.under-18-content h1 {
    color: #1a365d;
    text-align: center;
    margin-bottom: 2rem;
}

.youth-resources {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.youth-resource-card {
    background-color: #f7fafc;
    padding: 2rem;
    border-radius: 8px;
    border-left: 4px solid #3182ce;
    text-align: center;
}

.youth-resource-card h3 {
    color: #3182ce;
    margin-bottom: 1rem;
}

.youth-resource-card .emergency-number {
    font-size: 1.5rem;
    font-weight: 600;
    color: #e53e3e;
    text-decoration: none;
    display: block;
    margin-bottom: 0.5rem;
}

.parent-resources {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

.parent-resources h2 {
    color: #2d3748;
    margin-bottom: 1rem;
}

.parent-resources ul {
    padding-left: 2rem;
}

.parent-resources li {
    margin-bottom: 0.5rem;
}

/* Opt-out Styles */
.optout-section {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.optout-section:last-of-type {
    border-bottom: none;
}

.optout-section h4 {
    margin-bottom: 1rem;
    color: #2d3748;
}

.optout-section .checkbox-label {
    display: block;
    margin-bottom: 1rem;
}

.optout-status {
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.optout-status.success {
    color: #38a169;
    background-color: #f0fff4;
    border: 1px solid #9ae6b4;
    color: #276749;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.success-message {
    background-color: #f0fff4;
    border: 1px solid #9ae6b4;
}

.optout-status.warning {
    color: #d69e2e;
    background-color: #fffbf0;
    border: 1px solid #f6e05e;
}

.optout-status.info {
    color: #3182ce;
    background-color: #ebf8ff;
    border: 1px solid #90cdf4;
}

.optout-footer {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}

.optout-footer small {
    color: #718096;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        gap: 1rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-subtext {
        font-size: 1.125rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .trust-strip {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .trust-items {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .trust-items span::after {
        display: none;
    }
    
    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-buttons {
        justify-content: center;
    }
    
    .urgent-contacts {
        grid-template-columns: 1fr;
    }
    
    .contact-options {
        grid-template-columns: 1fr;
    }
    
    .emergency-grid {
        grid-template-columns: 1fr;
    }
    
    .cookie-modal-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        padding: 2rem 0;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .btn-large {
        padding: 14px 24px;
        font-size: 1rem;
    }
    
    .help-grid,
    .resource-cards {
        grid-template-columns: 1fr;
    }
    
    .urgent-help-box,
    .contact-form-section {
        padding: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 2px solid #000;
        background-color: #000;
        color: #fff;
    }
    
    .btn-secondary {
        border: 2px solid #000;
        background-color: #fff;
        color: #000;
    }
    
    .help-card,
    .resource-card {
        border: 1px solid #000;
    }
    
    a {
        color: #0000EE;
        text-decoration: underline;
    }
    
    a:visited {
        color: #551A8B;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}