:root {
    --primary-color: #002E5D; /* BYU Navy */
    --primary-light: #004a94;
    --accent-color: #A39161;  /* Academic Gold */
    --accent-light: #c5b38a;
    --secondary-color: #64748b;
    --bg-color: #ffffff;
    --bg-light: #f8fafc;
    --text-color: #0f172a;
    --text-muted: #475569;
    --font-main: 'Inter', sans-serif;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Animations */
.reveal {
    position: relative;
    transform: translateY(20px);
    opacity: 0;
    transition: 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    transform: translateY(0);
    opacity: 1;
}

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

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 10%;
    position: fixed;
    width: 100%;
    top: 0;
    background: transparent;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 1rem 10%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid rgba(0, 46, 93, 0.1);
}

.logo {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary-color);
    letter-spacing: 0.05em;
    position: relative;
}

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

.nav-links a {
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--primary-color);
}

.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 12rem 10% 8rem;
    min-height: 100vh;
    background: radial-gradient(circle at top right, #f1f5f9, #ffffff);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    width: 150%;
    height: 150%;
    background-image: radial-gradient(var(--accent-color) 0.5px, transparent 0.5px);
    background-size: 48px 48px;
    opacity: 0.05;
    z-index: 0;
    animation: pulse 10s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.1); }
}

.hero-content {
    max-width: 900px;
    z-index: 1;
    margin-bottom: 5rem;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5rem);
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.hero p {
    font-size: clamp(1.125rem, 2vw, 1.35rem);
    color: var(--text-muted);
    margin-bottom: 3.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.hero-btns {
    display: flex;
    gap: 1.25rem;
    justify-content: center;
}

.btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--primary-color);
    color: white;
    border-radius: 9999px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.875rem;
    border: 2px solid var(--primary-color);
    box-shadow: var(--shadow-md);
}

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

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    box-shadow: none;
}

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

.hero-image {
    display: flex;
    justify-content: center;
    position: relative;
    width: 100%;
    z-index: 1;
}

.hero-image::after {
    content: '';
    position: absolute;
    top: 30px;
    left: calc(50% + 20px);
    transform: translateX(-50%);
    width: 380px;
    height: 100%;
    border: 3px solid var(--accent-color);
    border-radius: 20px;
    z-index: -1;
    opacity: 0.5;
}

.hero-image img {
    max-width: 380px;
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: var(--shadow-xl);
}

.section {
    padding: 10rem 10%;
}

.section h2 {
    font-size: clamp(2rem, 5vw, 2.75rem);
    color: var(--primary-color);
    margin-bottom: 6rem;
    text-align: center;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.section h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    margin: 1.5rem auto 0;
    border-radius: 2px;
}

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

.about-text {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.25rem;
    text-align: center;
    color: var(--text-muted);
    line-height: 1.8;
}

.about-text p {
    margin-bottom: 2rem;
}

.about-text strong {
    color: var(--primary-color);
    font-weight: 700;
}

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

.skill-card {
    background: white;
    padding: 4rem 2.5rem;
    border-radius: 24px;
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: var(--shadow-md);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.skill-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-xl);
}

.skill-icon {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 2rem;
    background: #f1f5f9;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    transition: var(--transition);
}

.skill-card:hover .skill-icon {
    background: var(--primary-color);
    color: white;
    transform: rotate(5deg);
}

.skill-card h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1.25rem;
    font-weight: 800;
}

.skill-card p {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.6;
}

#contact {
    text-align: center;
    background: var(--primary-color);
    background: linear-gradient(135deg, var(--primary-color) 0%, #001e3d 100%);
    color: white;
    padding: 10rem 10%;
    position: relative;
    overflow: hidden;
}

#contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

#contact h2 {
    color: white;
    margin-bottom: 2rem;
    position: relative;
}

#contact h2::after {
    background: white;
}

#contact p {
    margin-bottom: 4rem;
    font-size: 1.25rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
    position: relative;
}

#contact .btn {
    background: white;
    color: var(--primary-color);
    border-color: white;
    padding: 1.25rem 3.5rem;
    font-size: 1rem;
    position: relative;
}

#contact .btn:hover {
    background: transparent;
    color: white;
}

footer {
    text-align: center;
    padding: 5rem 10%;
    background-color: #020617;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.1em;
}

@media (max-width: 1024px) {
    .section { padding: 8rem 5%; }
    .hero-image img, .hero-image::after { width: 320px; }
    .hero-image::after { left: calc(50% + 15px); }
}

@media (max-width: 768px) {
    .navbar { padding: 1.5rem 5%; }
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 2rem;
        text-align: center;
        gap: 1.5rem;
        box-shadow: var(--shadow-lg);
    }
    .nav-links.active {
        display: flex;
    }
    .nav-toggle {
        display: block;
    }
    .hero { padding-top: 10rem; }
    .hero-content { margin-bottom: 4rem; }
    .hero-image::after { display: none; }
    .hero-image img { max-width: 300px; }
    .section { padding: 6rem 5%; }
    .skills-grid { grid-template-columns: 1fr; }
}