/**
 * AEO Mastery - Site Styles
 * Primary Colors: Navy #1a365d, Amber #ed8936
 */

:root {
    --navy: #1a365d;
    --navy-light: #2c5282;
    --navy-dark: #0f2744;
    --amber: #ed8936;
    --amber-light: #f6ad55;
    --amber-dark: #c05621;
    --gray-50: #f7fafc;
    --gray-100: #edf2f7;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e0;
    --gray-400: #a0aec0;
    --gray-500: #718096;
    --gray-600: #4a5568;
    --gray-700: #2d3748;
    --gray-800: #1a202c;
    --white: #ffffff;
    --success: #48bb78;
    --warning: #ecc94b;
    --danger: #f56565;
    --info: #4299e1;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--navy);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
}

a {
    color: var(--amber);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--amber-light);
}

/* Header & Navigation */
.site-header {
    background: var(--navy);
    color: var(--white);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.site-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.site-logo span {
    color: var(--amber);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.main-nav a {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    opacity: 0.9;
    transition: opacity 0.2s;
}

.main-nav a:hover {
    opacity: 1;
}

.main-nav a.active {
    opacity: 1;
    position: relative;
}

.main-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -24px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--amber);
}

.nav-cta {
    background: var(--amber);
    color: var(--white) !important;
    padding: 0.625rem 1.25rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.2s;
}

.nav-cta:hover {
    background: var(--amber-light);
    transform: translateY(-1px);
}

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

.page-header h1 {
    font-size: 2.75rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--white);
}

.page-header p {
    font-size: 1.25rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.breadcrumbs {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
    opacity: 0.8;
}

.breadcrumbs a {
    color: var(--white);
}

.breadcrumbs span {
    opacity: 0.6;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--amber);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--amber-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

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

.btn-outline {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

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

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
}

/* Tool Container */
.tool-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
}

.tool-wrapper {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

/* Context Section */
.context-section {
    background: var(--gray-50);
    padding: 2rem;
    border-bottom: 1px solid var(--gray-200);
}

.context-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.context-section p {
    color: var(--gray-600);
    margin-bottom: 1rem;
}

.context-section a {
    color: var(--amber);
    font-weight: 600;
}

/* Tool Interface */
.tool-interface {
    padding: 2.5rem;
}

/* Form Elements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-label .help-text {
    font-weight: normal;
    color: var(--gray-500);
    font-size: 0.8rem;
    display: block;
    margin-top: 0.25rem;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--amber);
    box-shadow: 0 0 0 3px rgba(237, 137, 54, 0.1);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* Email Capture */
.email-capture {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    color: var(--white);
    padding: 2.5rem;
    text-align: center;
}

.email-capture h3 {
    color: var(--white);
    margin-bottom: 0.75rem;
}

.email-capture p {
    opacity: 0.9;
    margin-bottom: 1.5rem;
}

.email-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
}

.email-form .form-input {
    flex: 1;
    border: none;
}

.email-form .btn {
    white-space: nowrap;
}

.privacy-note {
    font-size: 0.8rem;
    opacity: 0.7;
    margin-top: 1rem;
}

/* Related Tools */
.related-tools {
    padding: 2.5rem;
    background: var(--gray-50);
    border-top: 1px solid var(--gray-200);
}

.related-tools h3 {
    margin-bottom: 1.5rem;
    text-align: center;
}

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

.tool-card {
    background: var(--white);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: inherit;
}

.tool-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.tool-card-icon {
    width: 48px;
    height: 48px;
    background: rgba(237, 137, 54, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.tool-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.tool-card p {
    font-size: 0.9rem;
    color: var(--gray-600);
    margin-bottom: 0;
}

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

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

.cta-section p {
    font-size: 1.125rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 1.5rem;
}

.guarantee {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    font-size: 0.9rem;
    opacity: 0.8;
}

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

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

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-brand {
    max-width: 300px;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--white);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.footer-logo span {
    color: var(--amber);
}

.footer-brand p {
    opacity: 0.7;
    font-size: 0.9rem;
}

.footer-links h4 {
    color: var(--white);
    font-size: 1rem;
    margin-bottom: 1rem;
}

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

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--gray-400);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

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

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
}

.affiliate-disclosure {
    font-size: 0.8rem;
    opacity: 0.6;
    margin-bottom: 1rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.copyright {
    opacity: 0.7;
    font-size: 0.875rem;
}

/* Loading State */
.loading {
    display: none;
    text-align: center;
    padding: 3rem;
}

.loading.active {
    display: block;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--gray-200);
    border-top-color: var(--amber);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Results Area */
.results {
    display: none;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--gray-200);
}

.results.active {
    display: block;
}

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--success);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s;
    z-index: 2000;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Mobile Responsive */
@media (max-width: 968px) {
    .main-nav {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        background: rgba(255, 255, 255, 0.1);
        border: none;
        border-radius: 8px;
        color: var(--white);
        font-size: 1.5rem;
        cursor: pointer;
    }

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

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }

    .email-form {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .page-header h1 {
        font-size: 1.75rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .tool-interface {
        padding: 1.5rem;
    }

    .tools-grid {
        grid-template-columns: 1fr;
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.hidden { display: none; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}
