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

html {
    scroll-behavior: smooth;
}

:root {
    --bg-base: #0f1115;
    --bg-elevated: #151a22;
    --text-main: #f5f7fa;
    --text-body: #b8c1cc;
    --text-muted: #7a8494;
    --accent: #4f7df9;
    --glow: rgba(79, 125, 249, 0.25);
    --border: rgba(255, 255, 255, 0.08);
}

body {
    background: radial-gradient(circle at 50% 0%, #1a1f2b 0%, #0f1115 60%);
    min-height: 100vh;
    color: var(--text-main);
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
    background-size: 140px 140px;
    opacity: 0.45;
    z-index: 0;
}

body > * {
    position: relative;
    z-index: 1;
}

#logo {
    color: var(--text-main);
    text-align: center;
    width: fit-content;
    animation: hide-logo linear forwards;
    animation-timeline: scroll();
    animation-range: 0px 200px;
    pointer-events: none;
}

@keyframes hide-logo {
    0% {
        opacity: 1;
        max-width: 200px;
        margin-right: 0;
    }
    100% {
        opacity: 0;
        max-width: 0;
        margin-right: -2rem;
    }
}

#logo h1 {
    font-size: 2rem;
}

#logo h2 {
    font-weight: 100;
    font-size: 1.25rem;
}

header {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    padding: 0.75rem;
    background: linear-gradient(320deg, rgba(27, 33, 48, 0.75), rgba(16, 21, 31, 0.6));
    border: 0.1rem solid rgba(255, 255, 255, 0.14);
    border-radius: 50em;
    display: flex;
    padding-left: 2rem;
    padding-right: 2rem;
    width: fit-content;
    animation: shrink-header linear forwards;
    animation-timeline: scroll();
    animation-range: 0px 200px;
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

@keyframes shrink-header {
    0% {
        padding: 0.75rem;
        padding-left: 2rem;
        padding-right: 2rem;
    }
    100% {
        padding: 0rem;
        padding-left: 2rem;
        padding-right: 2rem;
    }
}

nav {
    width: fit-content;
    color: var(--text-main);
    padding: 0.5rem;
    align-items: center;
    display: flex;
    margin-left: 2rem;
    gap: 1.5rem;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    white-space: nowrap;
}

nav a {
    height: fit-content;
    color: inherit;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    cursor: pointer;
    font-weight: 300;
    text-shadow: 0 0 12px rgba(255, 255, 255, 0.15), 0 0 30px rgba(79, 125, 249, 0.15);
    position: relative;
}
#hero,
#services-section,
#pricing,
#contact {
    scroll-margin-top: 120px;
}

nav a:hover {
    font-weight: 500;
    text-shadow: 0 0 18px rgba(255, 255, 255, 0.35), 0 0 40px rgba(79, 125, 249, 0.5);
    color: var(--accent);
}

footer {
    padding: 0.75rem;
    background: linear-gradient(320deg, #1b2130, #10151f);
    margin: 1rem auto;
    border: 0.1rem solid var(--border);
    border-radius: 50em;
    display: flex;
    padding-left: 2rem;
    padding-right: 2rem;
    width: fit-content;
    color: var(--text-main);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

/* Hero Section */
#hero {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    opacity: 1;
    transition: opacity 0.5s ease;
}

#hero h3,
#services-section h3,
#pricing h3,
#contact h3 {
    font-weight: 300;
    --underline-width: 0%;
    text-align: center;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    position: relative;
    display: inline-block;
    cursor: default;
    transition: font-weight 0.3s ease;
    text-shadow: 0 0 18px rgba(255, 255, 255, 0.25), 0 0 40px var(--glow);
}

#hero h3 {
    font-size: 5rem;
}

#hero h3::after,
#services-section h3::after,
#pricing h3::after,
#contact h3::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    height: 4px;
    background: var(--accent);
    width: var(--underline-width);
    transition: width 0.3s ease;
}

#hero.fade-out {
    opacity: 0;
}

/* Services Section */
#services-section {
    width: 100%;
    min-height: 100vh;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.5s ease;
}

#services-section h3 {
    font-size: 3rem;
    margin: 0 auto 2rem;
    text-align: center;
    display: inline-block;
    width: fit-content;
}

#services-section.visible {
    opacity: 1;
}

#services-section.fade-out {
    opacity: 0.28;
}

.services-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
}

.services-left {
    position: sticky;
    top: 2rem;
    height: fit-content;
}

.image-container {
    position: relative;
    width: 100%;
    height: 500px;
    border-radius: 1rem;
    overflow: hidden;
    background: linear-gradient(320deg, #1b2130, #10151f);
    border: 0.1rem solid var(--border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
}

.service-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.service-image.active {
    opacity: 1;
}

.services-right {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    padding-bottom: 3rem;
}

.service-item {
    background: linear-gradient(320deg, #1b2130, #10151f);
    border: 0.1rem solid var(--border);
    border-radius: 1rem;
    padding: 2.5rem;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
}

.service-item h4 {
    font-size: 2rem;
    font-weight: 400;
    color: var(--text-main);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

.service-item p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-body);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

@media (max-width: 968px) {
    .services-container {
        grid-template-columns: 1fr;
    }
    
    .services-left {
        position: relative;
        top: 0;
    }
    
    #hero h3 {
        font-size: 3rem;
    }
}

#pricing {
    width: 100%;
    margin: 2rem 0;
    padding: 0 1.5rem;
    text-align: left;
    color: var(--text-main);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    opacity: 1;
    transition: opacity 0.5s ease;
}

#pricing.fade-out {
    opacity: 0.28;
}

#pricing h3 {
    font-size: 3rem;
    margin: 0 0 1.5rem;
    text-align: left;
}

.pricing-table {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    border-collapse: collapse;
    background: linear-gradient(320deg, #1b2130, #10151f);
    border-radius: 1rem;
    overflow: hidden;
    border: 0.1rem solid var(--border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
}

.pricing-table th, .pricing-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

.pricing-table th {
    background-color: rgba(0, 0, 0, 0.35);
    font-size: 1.25rem;
}

.pricing-table td {
    font-size: 1.15rem;
    color: var(--text-body);
}

.pricing-table tbody tr:last-child td {
    border-bottom: none;
}

@media (max-width: 600px) {
    .pricing-table th, .pricing-table td {
        font-size: 0.9rem;
        padding: 0.75rem;
    }
}

#contact {
    width: 100%;
    margin: 3rem 0 2rem;
    padding: 0 1.5rem;
    color: var(--text-main);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    text-align: left;
}

#contact h3 {
    font-size: 3rem;
    margin: 0 0 1.5rem;
    text-align: left;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 1.5rem;
    text-align: left;
}

.contact-details,
.contact-form {
    background: linear-gradient(320deg, #1b2130, #10151f);
    border: 0.1rem solid var(--border);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(10px);
}

.contact-details h4 {
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

.contact-details p {
    margin-bottom: 0.5rem;
    color: var(--text-body);
}

.social-links {
    list-style: none;
    margin-top: 0.75rem;
}

.social-links li {
    margin-bottom: 0.5rem;
}

.social-links a {
    color: var(--text-main);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.social-links a:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.contact-form {
    display: grid;
    gap: 0.6rem;
}

.contact-form label {
    font-size: 0.95rem;
    color: var(--text-body);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    background: rgba(9, 11, 15, 0.85);
    color: var(--text-main);
    border: 1px solid var(--border);
    border-radius: 0.6rem;
    padding: 0.7rem 0.8rem;
    font: inherit;
}

.contact-form button {
    margin-top: 0.4rem;
    padding: 0.8rem 1rem;
    border-radius: 0.6rem;
    border: 1px solid var(--border);
    background: linear-gradient(320deg, #2b3960, #18203b);
    color: var(--text-main);
    font: inherit;
    cursor: pointer;
    transition: filter 0.2s ease;
}

.contact-form button:hover {
    filter: brightness(1.15);
}

@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}
