/* cucaveles - Modern Educational Website Styles */

/* CSS Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

/* CSS Custom Properties */
:root {
    --primary-color: #4A90E2;
    --secondary-color: #FFB84D;
    --accent-color: #F39C12;
    --success-color: #27AE60;
    --text-dark: #2C3E50;
    --text-light: #7F8C8D;
    --bg-light: #F8F9FA;
    --bg-section: #FAFBFC;
    --border-color: #E1E8ED;
    --shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 5px 25px rgba(0, 0, 0, 0.15);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
    line-height: 1.2;
}

h2 {
    font-size: 2rem;
    line-height: 1.3;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

/* Layout Components */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 60px 0;
}

.section-alt {
    background-color: var(--bg-section);
}

/* Header Styles */
header {
    background: #fff;
    box-shadow: var(--shadow);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: var(--transition);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo svg {
    width: 32px;
    height: 32px;
    fill: var(--primary-color);
}

/* Navigation */
nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

nav a:hover,
nav a:focus {
    background-color: var(--bg-light);
    color: var(--primary-color);
}

nav a.active {
    background-color: var(--primary-color);
    color: white;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-dark);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 120px 0 80px;
    text-align: center;
    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="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero h1 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 3rem;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    color: white;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #357ABD;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background-color: white;
    color: var(--primary-color);
    border: 2px solid white;
}

.btn-secondary:hover,
.btn-secondary:focus {
    background-color: transparent;
    color: white;
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover,
.btn-outline:focus {
    background-color: var(--primary-color);
    color: white;
}

/* Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 1rem;
    fill: var(--primary-color);
}

.card h3 {
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.card p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature {
    text-align: center;
    padding: 1.5rem;
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
    background: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    fill: var(--primary-color);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
    background-color: white;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* Contact Info */
.contact-info {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--border-radius);
    margin-top: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.contact-item:last-child {
    margin-bottom: 0;
}

.contact-icon {
    width: 24px;
    height: 24px;
    fill: var(--primary-color);
}

/* Footer */
footer {
    background-color: var(--text-dark);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    color: white;
    margin-bottom: 1rem;
}

.footer-section p,
.footer-section a {
    color: #BDC3C7;
    text-decoration: none;
    line-height: 1.8;
}

.footer-section a:hover,
.footer-section a:focus {
    color: var(--secondary-color);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid #34495E;
    padding-top: 2rem;
    text-align: center;
    color: #BDC3C7;
    font-size: 0.9rem;
}

.footer-policies {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
}

.footer-policies a {
    color: #BDC3C7;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-policies a:hover,
.footer-policies a:focus {
    color: var(--secondary-color);
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--text-dark);
    color: white;
    padding: 1rem;
    z-index: 1001;
    transform: translateY(100%);
    transition: var(--transition);
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-banner.minimized {
    transform: translateY(calc(100% - 60px));
}

.cookie-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

.cookie-text {
    flex: 1;
    font-size: 0.9rem;
}

.cookie-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.cookie-toggle {
    background: none;
    border: none;
    color: var(--secondary-color);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.5rem;
}

.cookie-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

.cookie-btn.accept {
    background: var(--success-color);
    color: white;
}

.cookie-btn.decline {
    background: #E74C3C;
    color: white;
}

.cookie-btn.customize {
    background: transparent;
    color: var(--secondary-color);
    border: 1px solid var(--secondary-color);
}

.cookie-btn:hover,
.cookie-btn:focus {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Mobile Navigation */
    .mobile-menu-toggle {
        display: block;
    }
    
    nav ul {
        position: fixed;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1rem;
        box-shadow: var(--shadow);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }
    
    nav ul.show {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    nav ul li {
        width: 100%;
    }
    
    nav ul a {
        display: block;
        width: 100%;
        padding: 1rem;
        text-align: center;
    }
    
    /* Typography adjustments */
    h1 {
        font-size: 2rem;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    /* Layout adjustments */
    .container {
        padding: 0 15px;
    }
    
    .section {
        padding: 40px 0;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-policies {
        flex-direction: column;
        gap: 1rem;
    }
    
    /* Cookie banner adjustments */
    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-actions {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .card {
        padding: 1.5rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Accessibility Enhancements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0066CC;
        --text-dark: #000000;
        --border-color: #000000;
    }
    
    .card {
        border: 2px solid var(--border-color);
    }
}

/* Focus visible enhancement */
*:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Skip link for accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--text-dark);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: var(--border-radius);
    z-index: 2000;
}

.skip-link:focus {
    top: 6px;
}
