/* ====================================
   Iber Tidal Wave Energy España - Styles
   Plataforma de Gestión Inteligente Marina
   ==================================== */

/* Variables CSS */
:root {
    --primary-blue: #0066CC;
    --light-blue: #00AAFF;
    --dark-blue: #003D66;
    --energy-green: #00CC66;
    --light-green: #00FF99;
    --white: #FFFFFF;
    --light-gray: #F5F7FA;
    --medium-gray: #E0E4E8;
    --dark-gray: #2C3E50;
    --text-color: #333333;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Tipografía */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

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

p {
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Navegación */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--dark-blue) 0%, var(--primary-blue) 100%);
    padding: 1rem 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.navbar.scrolled {
    background: rgba(0, 61, 102, 0.95);
    backdrop-filter: blur(10px);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--white);
    font-size: 1.3rem;
    font-weight: 700;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--energy-green), var(--light-green));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

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

.nav-links a {
    color: var(--white);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    width: 28px;
    height: 3px;
    background: var(--white);
    border-radius: 2px;
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translateY(8px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-8px);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--dark-blue) 0%, var(--primary-blue) 50%, var(--light-blue) 100%);
    position: relative;
    overflow: hidden;
    padding: 6rem 2rem 4rem;
}

.hero::before {
    content: '';
    position: absolute;
    width: 150%;
    height: 150%;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>');
    animation: float 60s linear infinite;
}

@keyframes float {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(-50px, -50px) rotate(360deg); }
}

.hero-content {
    max-width: 1200px;
    text-align: center;
    color: var(--white);
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    animation: fadeInUp 1s ease 0.2s both;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease 0.4s both;
}

.btn {
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    display: inline-block;
}

.btn-primary {
    background: linear-gradient(135deg, var(--energy-green), var(--light-green));
    color: var(--white);
    box-shadow: 0 4px 15px rgba(0, 204, 102, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 204, 102, 0.5);
}

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

.btn-secondary:hover {
    background: var(--white);
    color: var(--primary-blue);
    transform: translateY(-3px);
}

/* Secciones */
.section {
    padding: 5rem 2rem;
}

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

.section-dark {
    background: linear-gradient(135deg, var(--dark-blue), var(--primary-blue));
    color: var(--white);
}

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

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--energy-green), var(--light-green));
    border-radius: 2px;
}

.section-header p {
    font-size: 1.2rem;
    opacity: 0.8;
}

/* Grid de Características */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
}

.section-dark .feature-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: var(--white);
}

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

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--primary-blue), var(--light-blue));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--white);
}

.section-dark .feature-icon {
    background: linear-gradient(135deg, var(--energy-green), var(--light-green));
}

.feature-card h3 {
    margin-bottom: 1rem;
    color: var(--dark-blue);
}

.section-dark .feature-card h3 {
    color: var(--white);
}

.feature-card p {
    opacity: 0.8;
    margin-bottom: 0;
}

/* Timeline */
.timeline {
    position: relative;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary-blue), var(--energy-green));
}

.timeline-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    position: relative;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-content {
    flex: 1;
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.timeline-dot {
    width: 20px;
    height: 20px;
    background: var(--energy-green);
    border-radius: 50%;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid var(--white);
    box-shadow: var(--shadow);
}

/* Formulario de Contacto */
.contact-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.contact-form {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark-blue);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--medium-gray);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

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

.contact-info {
    background: linear-gradient(135deg, var(--dark-blue), var(--primary-blue));
    color: var(--white);
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.contact-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    align-items: start;
}

.contact-item-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.map-container {
    margin-top: 2rem;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.map-container iframe {
    width: 100%;
    height: 300px;
    border: none;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--dark-blue), #001a33);
    color: var(--white);
    padding: 4rem 2rem 2rem;
}

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

.footer-section h3 {
    margin-bottom: 1.5rem;
    color: var(--energy-green);
}

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

.footer-section ul li {
    margin-bottom: 0.75rem;
}

.footer-section ul li a {
    opacity: 0.8;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    opacity: 1;
    color: var(--energy-green);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--energy-green);
    transform: translateY(-3px);
}

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

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--dark-blue), var(--primary-blue));
    color: var(--white);
    padding: 1.5rem;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.4s ease;
}

.cookie-banner.show {
    transform: translateY(0);
}

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

.cookie-text {
    flex: 1;
    min-width: 250px;
}

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

.cookie-btn {
    padding: 0.75rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.cookie-btn.accept {
    background: var(--energy-green);
    color: var(--white);
}

.cookie-btn.accept:hover {
    background: var(--light-green);
    transform: scale(1.05);
}

.cookie-btn.reject {
    background: rgba(255, 255, 255, 0.2);
    color: var(--white);
}

.cookie-btn.reject:hover {
    background: rgba(255, 255, 255, 0.3);
}

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

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--dark-blue);
        flex-direction: column;
        padding: 2rem;
        gap: 0;
        transform: translateX(100%);
        transition: var(--transition);
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .nav-links li {
        margin-bottom: 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .section {
        padding: 3rem 1.5rem;
    }

    .section-header h2 {
        font-size: 1.8rem;
    }

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

    .timeline::before {
        left: 30px;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        flex-direction: row;
        padding-left: 70px;
    }

    .timeline-dot {
        left: 30px;
    }

    .contact-section {
        grid-template-columns: 1fr;
    }

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

    .cookie-content {
        flex-direction: column;
        text-align: center;
    }

    .cookie-buttons {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }

    .btn {
        padding: 0.875rem 2rem;
        font-size: 1rem;
    }

    .feature-card {
        padding: 2rem;
    }
}
