/**
 * Brandon Lee Portfolio Styles
 * 
 * Description: Comprehensive CSS styling for a modern, responsive portfolio website
 * Author: Brandon Lee Cheng Yi
 * Version: 2.0
 * Last Updated: July 2025
 * 
 * Table of Contents:
 * 1. CSS Custom Properties (Variables)
 * 2. Reset and Base Styles
 * 3. Loading Animations
 * 4. Navigation Styles
 * 5. Hero Section
 * 6. Skills Section
 * 7. About Section
 * 8. Contact Section
 * 9. Footer Styles
 * 10. Legal Pages
 * 11. Responsive Design
 * 12. Accessibility Enhancements
 */

/* ===== 1. CSS CUSTOM PROPERTIES (VARIABLES) ===== */
:root {
    /* Color Palette */
    --primary-color: #4f46e5;      /* Indigo - Primary brand color */
    --secondary-color: #7c3aed;    /* Purple - Secondary brand color */
    --accent-color: #fde68a;       /* Yellow - Accent/highlight color */
    --text-primary: #1f2937;       /* Dark gray - Primary text */
    --text-secondary: #6b7280;     /* Medium gray - Secondary text */
    --text-light: #9ca3af;         /* Light gray - Tertiary text */
    --bg-primary: #f9fafb;         /* Light gray - Primary background */
    --bg-white: #ffffff;           /* White - Card backgrounds */
    --border-color: #e5e7eb;       /* Light gray - Borders */
    
    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);          /* Small shadow */
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);      /* Medium shadow */
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);    /* Large shadow */
    
    /* Transitions */
    --transition-fast: 0.15s ease-in-out;     /* Fast transitions */
    --transition-normal: 0.3s ease-in-out;    /* Normal transitions */
    --transition-slow: 0.5s ease-in-out;      /* Slow transitions */
    
    /* Layout */
    --max-width: 1280px;           /* Maximum container width */
    --nav-height: 4rem;            /* Navigation height */
    --section-padding: 4rem;       /* Section padding */
}

/* ===== 2. RESET AND BASE STYLES ===== */

/* Apply border-box sizing to all elements for consistent layout */
* {
    box-sizing: border-box;
}

/* Base body styles with modern typography and smooth scrolling */
body {
    font-family: 'Poppins', sans-serif;  /* Modern, clean font */
    scroll-behavior: smooth;              /* Smooth scrolling for anchor links */
    margin: 0;
    padding: 0;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    line-height: 1.6;                     /* Improved readability */
    -webkit-font-smoothing: antialiased;  /* Better font rendering */
    -moz-osx-font-smoothing: grayscale;   /* Better font rendering on macOS */
}

/* ===== 3. LOADING ANIMATIONS ===== */

/* Animation for elements sliding up from bottom */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Smooth scrolling enhancement with offset for fixed navigation */
html {
    scroll-padding-top: 5rem;
}

/* ===== 4. LAYOUT COMPONENTS ===== */

/* Main container with responsive max-width and padding */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1rem;
}

/* ===== 5. ACCESSIBILITY ENHANCEMENTS ===== */

/* Focus styles for keyboard navigation */
*:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Skip to main content link for screen readers */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --text-primary: #000000;
        --text-secondary: #000000;
        --bg-primary: #ffffff;
    }
}

/* Reduced motion support for users with vestibular disorders */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== 6. NAVIGATION STYLES ===== */
nav {
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    z-index: 10;
    transition: all 0.3s ease;
}

nav.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 4rem;
    padding: 0 1.5rem;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.logo:hover {
    opacity: 0.8;
}

.logo-primary {
    color: #4f46e5;
}

.logo-secondary {
    color: #1f2937;
}

.nav-links {
    display: none;
    list-style: none;
}

.nav-links a {
    color: #4b5563;
    text-decoration: none;
    margin-left: 2rem;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #4f46e5;
}

.mobile-menu-button {
    display: block;
    color: #6b7280;
    cursor: pointer;
}

.mobile-menu-button:hover {
    color: #4f46e5;
}

.mobile-menu {
    display: block;
    background-color: #ffffff;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    position: absolute;
    width: 100%;
    top: 100%;
    left: 0;
}

.mobile-menu.hidden {
    display: none;
}

.mobile-menu a {
    display: block;
    padding: 0.75rem 1rem;
    color: #4b5563;
    text-decoration: none;
    border-radius: 0.375rem;
}

.mobile-menu a:hover {
    color: #4f46e5;
    background-color: #f9fafb;
}

/* Hero Section */
.hero-bg {
    background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
    padding-top: 7rem;
    padding-bottom: 5rem;
    text-align: center;
}

.hero-badge {
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
    padding: 0.5rem;
    border-radius: 9999px;
    display: inline-block;
    margin-bottom: 1rem;
}

.hero-badge span {
    color: white;
    padding: 0 1rem;
}

.hero-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: white;
    margin-bottom: 1.5rem;
}

.hero-highlight {
    color: #fde68a;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #e0e7ff;
    max-width: 42rem;
    margin: 0 auto 2rem auto;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    justify-content: center;
}

.btn {
    display: inline-block;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: white;
    color: #4f46e5;
    border: 2px solid #4f46e5;
}

.btn-primary:hover {
    background-color: #4f46e5;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.btn-secondary {
    background-color: #4338ca;
    color: white;
    border: 2px solid #4338ca;
}

.btn-secondary:hover {
    background-color: #3730a3;
    border-color: #3730a3;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(67, 56, 202, 0.3);
}

/* Section Styles */
.section {
    padding: 4rem 0;
}

.section-white {
    background-color: white;
}

.section-gray {
    background-color: #f9fafb;
}

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

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 1rem;
}

.section-divider {
    height: 0.25rem;
    width: 5rem;
    background-color: #4f46e5;
    margin: 0 auto;
}

.section-subtitle {
    margin-top: 1rem;
    font-size: 1.25rem;
    color: #6b7280;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

.about-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.about-content p {
    color: #6b7280;
    margin-bottom: 1.5rem;
}

.about-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.tag {
    background-color: #e0e7ff;
    color: #4338ca;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
}

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

.image-container {
    position: relative;
}

.profile-circle {
    width: 16rem;
    height: 16rem;
    border-radius: 9999px;
    background-color: #4f46e5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.profile-icon {
    width: 12rem;
    height: 12rem;
    color: white;
}

.profile-image {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
}


.info-cards {
    margin-top: 5rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.info-card {
    background-color: #f9fafb;
    padding: 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid #f3f4f6;
}

.card-icon {
    width: 3rem;
    height: 3rem;
    background-color: #e0e7ff;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.card-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    color: #4f46e5;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.card-text {
    color: #6b7280;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.skill-card {
    background-color: var(--bg-white);
    padding: 2rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out forwards;
}

.skill-card:nth-child(1) {
    animation-delay: 0.1s;
}

.skill-card:nth-child(2) {
    animation-delay: 0.2s;
}

.skill-card:nth-child(3) {
    animation-delay: 0.3s;
}

.skill-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease-in-out;
}

.skill-card:hover::before {
    left: 100%;
}

.skill-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.skill-card:hover .skill-icon {
    transform: scale(1.1) rotate(5deg);
    animation: pulse 2s infinite;
}

.skill-card:hover .skill-title {
    color: var(--primary-color);
    transform: translateX(5px);
}

.skill-card:hover .skill-list li {
    transform: translateX(10px);
}

.skill-card:hover .skill-list li:nth-child(1) {
    transition-delay: 0.1s;
}

.skill-card:hover .skill-list li:nth-child(2) {
    transition-delay: 0.2s;
}

.skill-card:hover .skill-list li:nth-child(3) {
    transition-delay: 0.3s;
}

.skill-card:hover .skill-list li:nth-child(4) {
    transition-delay: 0.4s;
}

.skill-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.skill-icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transition: all var(--transition-normal);
    transform: translate(-50%, -50%);
}

.skill-card:hover .skill-icon::before {
    width: 100%;
    height: 100%;
}

.skill-icon.blue {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
}

.skill-icon.blue svg {
    color: #2563eb;
    transition: all var(--transition-normal);
}

.skill-icon.green {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
}

.skill-icon.green svg {
    color: #059669;
    transition: all var(--transition-normal);
}

.skill-icon.purple {
    background: linear-gradient(135deg, #ede9fe 0%, #ddd6fe 100%);
}

.skill-icon.purple svg {
    color: #7c3aed;
    transition: all var(--transition-normal);
}

.skill-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    transition: all var(--transition-normal);
    position: relative;
}

.skill-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width var(--transition-normal);
}

.skill-card:hover .skill-title::after {
    width: 100%;
}

.skill-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.skill-list li {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    transition: all var(--transition-normal);
    position: relative;
    padding-left: 10px;
}

.skill-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width var(--transition-normal);
    transform: translateY(-50%);
}

.skill-card:hover .skill-list li::before {
    width: 5px;
}

.skill-list li:last-child {
    margin-bottom: 0;
}

.check-icon {
    width: 1.25rem;
    height: 1.25rem;
    color: #10b981;
    margin-right: 0.75rem;
    flex-shrink: 0;
    transition: all var(--transition-normal);
}

.skill-card:hover .check-icon {
    color: var(--primary-color);
    transform: scale(1.2);
}

.skill-name {
    color: var(--text-secondary);
    transition: all var(--transition-normal);
    font-weight: 500;
}

.skill-card:hover .skill-name {
    color: var(--text-primary);
    font-weight: 600;
}

.projects {
    margin-top: 5rem;
}

.projects-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 2rem;
    text-align: center;
}

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

.project-card {
    background-color: white;
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #f3f4f6;
}

.project-image {
    height: 12rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-image.blue {
    background: linear-gradient(to right, #3b82f6, #4f46e5);
}

.project-image.green {
    background: linear-gradient(to right, #10b981, #059669);
}

.project-image svg {
    width: 5rem;
    height: 5rem;
    color: white;
}

.project-content {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.project-description {
    color: #6b7280;
    margin-bottom: 1rem;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-tag {
    background-color: #dbeafe;
    color: #1e40af;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.project-tag.green {
    background-color: #d1fae5;
    color: #065f46;
}

.project-link {
    color: #4f46e5;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.project-link:hover {
    color: #4338ca;
}

.project-link svg {
    width: 1rem;
    height: 1rem;
    margin-left: 0.25rem;
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.contact-info {
    background-color: #f9fafb;
    padding: 2rem;
    border-radius: 0.75rem;
    border: 1px solid #f3f4f6;
}

.contact-info-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1.5rem;
}

.contact-details {
    margin-bottom: 1.5rem;
}

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

.contact-icon {
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    background-color: #e0e7ff;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-icon svg {
    width: 1.25rem;
    height: 1.25rem;
    color: #4f46e5;
}

.contact-text {
    margin-left: 1rem;
}

.contact-label {
    color: #4b5563;
    font-weight: 500;
}

.contact-value {
    color: #6b7280;
}

.contact-value a {
    color: #4f46e5;
    text-decoration: none;
}

.contact-value a:hover {
    color: #4338ca;
}

.social-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

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

.social-link {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: background-color 0.3s;
}

.social-link.facebook {
    background-color: #1877f2;
}

.social-link.facebook:hover {
    background-color: #166fe5;
}

.social-link.twitter {
    background-color: #1da1f2;
}

.social-link.twitter:hover {
    background-color: #1a91da;
}

.social-link.linkedin {
    background-color: #0077b5;
}

.social-link.linkedin:hover {
    background-color: #006699;
}

.social-link.github {
    background-color: #333333;
}

.social-link.github:hover {
    background-color: #000000;
}

.social-link.instagram {
    background-color: #E4405F;
}

.social-link.instagram:hover {
    background-color: #d73651;
}

.social-link svg,
.social-link i {
    width: 1.25rem;
    height: 1.25rem;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background-color: white;
    padding: 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-form:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px -5px rgba(0, 0, 0, 0.1);
}

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

.form-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #4b5563;
    margin-bottom: 0.25rem;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-input:focus {
    outline: none;
    border-color: #4f46e5;
    box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.2);
}

.form-textarea {
    resize: vertical;
    min-height: 8rem;
}

.form-button {
    width: 100%;
    background-color: #4f46e5;
    color: white;
    font-weight: 500;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: background-color 0.3s;
}

.form-button:hover {
    background-color: #4338ca;
}

.form-disclaimer {
    text-align: center;
    font-size: 0.875rem;
    color: #9ca3af;
    margin-top: 1rem;
}

/* Form Validation Styles */
.field-error {
    color: #ef4444 !important;
    font-size: 0.875rem !important;
    margin-top: 0.25rem !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.field-error::before {
    content: "⚠️";
    font-size: 0.75rem;
}

.form-input.error,
.form-textarea.error {
    border-color: #ef4444 !important;
    background-color: #fef2f2;
}

.form-input.valid,
.form-textarea.valid {
    border-color: #10b981 !important;
    background-color: #f0fdf4;
}

.success-message {
    background-color: #10b981 !important;
    color: white !important;
    padding: 1rem !important;
    border-radius: 0.5rem !important;
    margin-top: 1rem !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: fadeInUp 0.5s ease-out !important;
}

.success-message::before {
    content: "✅";
    font-size: 1.2rem;
}

/* Enhanced Form Button States */
.form-button {
    position: relative;
    overflow: hidden;
}

.button-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.button-loading.hidden {
    display: none;
}

.form-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.form-button:disabled:hover {
    background-color: #4f46e5;
    transform: none;
}

/* Form Input Focus States */
.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* Placeholder Styles */
.form-input::placeholder,
.form-textarea::placeholder {
    color: #9ca3af;
    opacity: 1;
}

/* Character Counter */
.character-counter {
    font-size: 0.75rem;
    color: #6b7280;
    text-align: right;
    margin-top: 0.25rem;
}

.character-counter.warning {
    color: #f59e0b;
}

.character-counter.error {
    color: #ef4444;
}

/* Loading Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all var(--transition-normal);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 15px 25px -3px rgba(79, 70, 229, 0.3);
}

.back-to-top:active {
    transform: translateY(0);
}

.back-to-top svg {
    transition: transform var(--transition-fast);
}

.back-to-top:hover svg {
    transform: translateY(-2px);
}

/* Back to Top Button Mobile */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .back-to-top svg {
        width: 20px;
        height: 20px;
    }
}

/* Back to Top Animation */
@keyframes bounceUp {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

.back-to-top.animate {
    animation: bounceUp 0.8s ease-in-out;
}

/* Legal Pages */
.legal-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
}

.legal-section {
    margin-bottom: 2rem;
}

.legal-section h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.legal-section p {
    color: #6b7280;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.legal-section ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.legal-section li {
    color: #6b7280;
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.legal-section a {
    color: #4f46e5;
    text-decoration: none;
}

.legal-section a:hover {
    text-decoration: underline;
}

.legal-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
    text-align: center;
}

.legal-footer p {
    color: #6b7280;
    font-size: 0.875rem;
}

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

.footer-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
}

.footer-logo {
    margin-bottom: 1rem;
}

.footer-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

.footer-brand-accent {
    color: #a5b4fc;
}

.footer-tagline {
    margin-top: 0.25rem;
    color: #9ca3af;
    font-size: 1rem;
}

.footer-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    list-style: none;
    padding: 0;
}

.footer-link {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 1rem;
}

.footer-link:hover {
    color: white;
}

.footer-bottom {
    width: 100%;
    border-top: 1px solid #374151;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.footer-copyright {
    color: #9ca3af;
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

.footer-legal {
    display: flex;
    align-items: center;
}

.footer-legal-link {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 1rem;
}

.footer-legal-link:hover {
    color: #d1d5db;
}

.footer-divider {
    margin: 0 0.5rem;
    color: #4b5563;
}

/* Responsive Styles */
@media (min-width: 640px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-buttons {
        flex-direction: row;
    }
    
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .section {
        padding: 6rem 0;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
    
    .about-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .about-content {
        order: 1;
    }
    
    .about-image {
        order: 2;
    }
    
    .info-cards {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }
    
    .footer-logo {
        margin-bottom: 0;
    }
    
    .footer-links {
        flex-direction: row;
        margin-bottom: 0;
        gap: 2rem;
    }
    
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        margin-top: 1.25rem;
        padding-top: 1.25rem;
    }
    
    .footer-copyright {
        margin-bottom: 0;
    }
}

@media (min-width: 1024px) {
    .nav-links {
        display: flex;
    }
    
    .mobile-menu-button {
        display: none;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
    
    .contact-grid {
        grid-template-columns: 1fr 1fr;
    }
}