/* PerfoScan.ai Landing Page Styles */

/* CSS Variables */
:root {
    --primary-blue: #1a3a5c;
    --primary-blue-light: #2d5a87;
    --primary-blue-dark: #0d2137;
    --accent-green: #4CAF50;
    --accent-red: #f44336;
    --text-dark: #333333;
    --text-light: #ffffff;
    --text-muted: #666666;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --gradient-blue: linear-gradient(135deg, #1a3a5c 0%, #2d5a87 50%, #1a3a5c 100%);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.15);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-white);
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.3;
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    margin-bottom: 1rem;
}

h3 {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
}

p {
    font-size: clamp(1rem, 2vw, 1.1rem);
}

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

/* Header */
.header {
    background: var(--gradient-blue);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-soft);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 50px;
    width: auto;
    border-radius: 50%;
}

.logo-text {
    color: var(--text-light);
    font-size: 1.5rem;
    font-weight: 600;
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    opacity: 0.9;
}

.nav-links a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.5rem;
    cursor: pointer;
}

.language-selector {
    position: relative;
}

.language-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    padding: 8px 16px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition);
}

.language-btn:hover,
.language-selector.open .language-btn {
    background: rgba(255, 255, 255, 0.2);
}

.language-btn:focus-visible {
    outline: 2px solid var(--text-light);
    outline-offset: 3px;
}

.language-btn .dropdown-arrow {
    font-size: 0.75rem;
    transition: var(--transition);
}

.language-selector.open .dropdown-arrow {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    list-style: none;
    background: var(--bg-white);
    color: var(--text-dark);
    border-radius: var(--border-radius);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
    padding: 10px;
    min-width: 210px;
    max-height: 70vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: var(--transition);
    z-index: 1200;
}

.language-dropdown.drop-up {
    top: auto;
    bottom: calc(100% + 10px);
}

.language-dropdown.open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition);
}

.language-option:hover,
.language-option:focus-visible {
    background: rgba(26, 58, 92, 0.08);
    outline: none;
}

.language-option[aria-selected="true"] {
    background: var(--primary-blue-light);
    color: var(--text-light);
}

.language-option .flag {
    font-size: 1.1rem;
}

.language-label {
    white-space: nowrap;
}

/* Hero Section */
.hero {
    background: var(--gradient-blue);
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="snow" patternUnits="userSpaceOnUse" width="100" height="100"><circle cx="10" cy="10" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="50" cy="30" r="0.5" fill="rgba(255,255,255,0.08)"/><circle cx="80" cy="60" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="30" cy="80" r="0.5" fill="rgba(255,255,255,0.08)"/></pattern></defs><rect fill="url(%23snow)" width="100" height="100"/></svg>');
    opacity: 0.5;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content {
    color: var(--text-light);
}

.hero-content h1 {
    margin-bottom: 20px;
}

.hero-content .tagline {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    opacity: 0.9;
    margin-bottom: 30px;
}

.hero-image {
    display: flex;
    justify-content: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    max-height: 500px;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.3));
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--text-light);
    color: var(--primary-blue);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.3);
}

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

.btn-outline:hover {
    background: var(--text-light);
    color: var(--primary-blue);
}

.btn-subscribe {
    background: var(--accent-green);
    color: var(--text-light);
}

.btn-subscribe:hover {
    background: #45a049;
    transform: translateY(-2px);
}

/* Section Styles */
.section {
    padding: 80px 0;
}

.section-light {
    background: var(--bg-white);
}

.section-gray {
    background: var(--bg-light);
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    color: var(--primary-blue);
}

.section-header p {
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* Features Section */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.feature-card {
    background: var(--bg-white);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 2rem;
}

.feature-card h3 {
    color: var(--primary-blue);
    margin-bottom: 15px;
}

.feature-card p {
    color: var(--text-muted);
}

/* How It Works Section */
.how-it-works {
    background: var(--bg-light);
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-top: 40px;
}

.step {
    text-align: center;
    padding: 30px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--gradient-blue);
    color: var(--text-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

.step h3 {
    color: var(--primary-blue);
    margin-bottom: 10px;
}

/* Technique Comparison */
.technique-section {
    background: var(--bg-white);
}

.technique-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
}

.technique-card {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.technique-card.good {
    border: 3px solid var(--accent-green);
}

.technique-card.wrong {
    border: 3px solid var(--accent-red);
}

.technique-card img {
    width: 100%;
    height: auto;
    display: block;
}

.technique-card-content {
    padding: 25px;
    background: var(--bg-white);
}

.technique-card.good .technique-card-content h3 {
    color: var(--accent-green);
}

.technique-card.wrong .technique-card-content h3 {
    color: var(--accent-red);
}

.technique-badge {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.badge-good {
    background: rgba(76, 175, 80, 0.1);
    color: var(--accent-green);
}

.badge-warning {
    background: rgba(244, 67, 54, 0.1);
    color: var(--accent-red);
}

/* App Showcase */
.app-showcase {
    background: var(--gradient-blue);
    color: var(--text-light);
}

.app-showcase .section-header h2,
.app-showcase .section-header p {
    color: var(--text-light);
}

.app-showcase .section-header p {
    opacity: 0.9;
}

.app-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

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

.app-image img {
    max-width: 300px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.3));
}

.app-features {
    list-style: none;
}

.app-features li {
    padding: 15px 0;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    gap: 15px;
}

.app-features li:last-child {
    border-bottom: none;
}

.check-icon {
    width: 24px;
    height: 24px;
    background: var(--accent-green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.app-store-badge {
    margin-top: 30px;
}

.app-store-badge img {
    height: 50px;
    width: auto;
    transition: var(--transition);
}

.app-store-badge img:hover {
    transform: scale(1.05);
}

/* Newsletter Section */
.newsletter {
    background: var(--bg-light);
    text-align: center;
}

.newsletter-form {
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.newsletter-form input[type="email"] {
    flex: 1;
    min-width: 250px;
    padding: 15px 25px;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    font-size: 1rem;
    transition: var(--transition);
}

.newsletter-form input[type="email"]:focus {
    outline: none;
    border-color: var(--primary-blue);
}

.newsletter-message {
    width: 100%;
    padding: 15px;
    border-radius: var(--border-radius);
    margin-top: 20px;
    display: none;
}

.newsletter-message.success {
    background: rgba(76, 175, 80, 0.1);
    color: var(--accent-green);
    display: block;
}

.newsletter-message.error {
    background: rgba(244, 67, 54, 0.1);
    color: var(--accent-red);
    display: block;
}

/* Footer */
.footer {
    background: var(--primary-blue-dark);
    color: var(--text-light);
    padding: 60px 0 30px;
}

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

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.footer-brand img {
    height: 40px;
    border-radius: 50%;
}

.footer-section h4 {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

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

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--text-light);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 30px;
    text-align: center;
    opacity: 0.7;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-image {
        order: -1;
    }

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

    .app-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .app-image {
        order: -1;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--primary-blue);
        flex-direction: column;
        padding: 20px;
        gap: 15px;
        text-align: center;
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: block;
    }

    .header nav {
        gap: 10px;
    }

    .language-selector {
        margin-left: auto;
    }

    .language-dropdown {
        right: auto;
        left: 0;
    }

    .section {
        padding: 60px 0;
    }

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

    .newsletter-form input[type="email"],
    .newsletter-form button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 100px 0 60px;
    }

    .feature-card {
        padding: 30px 20px;
    }

    .step {
        padding: 20px 10px;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

/* Loading Spinner */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

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