/* ============================================================
   ALMIR.AT — Personal Brand Website
   KI Specialist · KI Designer
   ============================================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-bg: #060608;
    --color-bg-elevated: #0c0c10;
    --color-bg-card: #111116;
    --color-bg-card-hover: #16161d;
    --color-surface: #1a1a22;
    --color-border: rgba(255, 255, 255, 0.06);
    --color-border-hover: rgba(255, 255, 255, 0.12);
    --color-text: #e8e8ed;
    --color-text-secondary: #8a8a9a;
    --color-text-muted: #55556a;
    --color-accent: #a78bfa;
    --color-accent-soft: rgba(167, 139, 250, 0.12);
    --color-accent-glow: rgba(167, 139, 250, 0.25);
    --color-white: #ffffff;

    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-display: 'Space Grotesk', 'Inter', sans-serif;

    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

    --nav-height: 80px;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* --- Container --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Section Shared --- */
.section-label {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 20px;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--color-white);
    margin-bottom: 24px;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 32px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.3s var(--ease-out);
    white-space: nowrap;
}

.btn--primary {
    background: var(--color-accent);
    color: #0a0a0f;
}

.btn--primary:hover {
    background: #b89dfc;
    transform: translateY(-1px);
    box-shadow: 0 8px 30px var(--color-accent-glow);
}

.btn--ghost {
    background: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border-hover);
}

.btn--ghost:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    background: var(--color-accent-soft);
}

.btn--full {
    width: 100%;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    z-index: 1000;
    transition: background 0.4s ease, box-shadow 0.4s ease;
}

.nav--scrolled {
    background: rgba(6, 6, 8, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 var(--color-border);
}

.nav__inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav__logo {
    display: flex;
    align-items: center;
}

.nav__logo-img {
    height: 64px;
    width: auto;
    object-fit: contain;
    filter: brightness(1.1);
    transition: filter 0.3s ease;
}

.nav__logo:hover .nav__logo-img {
    filter: brightness(1.3) drop-shadow(0 0 12px rgba(255, 100, 120, 0.4));
}

/* Footer logo bigger */
.footer__brand .nav__logo-img {
    height: 80px;
}

.nav__links {
    display: flex;
    align-items: center;
    gap: 36px;
}

.nav__links a {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--color-text-secondary);
    transition: color 0.25s ease;
}

.nav__links a:hover {
    color: var(--color-white);
}

.nav__cta {
    padding: 8px 20px !important;
    border: 1px solid var(--color-border-hover) !important;
    border-radius: 6px !important;
    color: var(--color-text) !important;
    transition: all 0.25s ease !important;
}

.nav__cta:hover {
    border-color: var(--color-accent) !important;
    color: var(--color-accent) !important;
    background: var(--color-accent-soft) !important;
}

/* Mobile Toggle */
.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav__toggle span {
    display: block;
    width: 24px;
    height: 1.5px;
    background: var(--color-text);
    transition: all 0.3s var(--ease-out);
}

.nav__toggle.active span:first-child {
    transform: rotate(45deg) translate(3px, 3px);
}

.nav__toggle.active span:last-child {
    transform: rotate(-45deg) translate(3px, -3px);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 24px 80px;
}

/* ============================================================
   GLOBAL BACKGROUND EFFECTS (full page, fixed)
   ============================================================ */

/* --- Canvas Particle Network --- */
.bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/* --- Code Rain Overlay --- */
.bg-code-rain {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.bg-code-rain .code-col {
    position: absolute;
    top: -120%;
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.7;
    color: var(--color-accent);
    opacity: 0;
    white-space: nowrap;
    user-select: none;
    animation: codefall linear infinite;
    text-shadow: 0 0 12px var(--color-accent-glow);
}

@keyframes codefall {
    0% { transform: translateY(0); opacity: 0; }
    3% { opacity: 1; }
    90% { opacity: 1; }
    100% { transform: translateY(calc(100vh + 300px)); opacity: 0; }
}

/* --- Floating Orbs --- */
.bg-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

.bg-orb--1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(167, 139, 250, 0.22) 0%, transparent 60%);
    top: 5%;
    right: -5%;
    animation: orbDrift1 18s ease-in-out infinite;
}

.bg-orb--2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(129, 140, 248, 0.18) 0%, transparent 60%);
    top: 40%;
    left: -8%;
    animation: orbDrift2 22s ease-in-out infinite;
    animation-delay: -7s;
}

.bg-orb--3 {
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(196, 181, 253, 0.14) 0%, transparent 60%);
    bottom: 10%;
    right: 20%;
    animation: orbDrift3 25s ease-in-out infinite;
    animation-delay: -12s;
}

@keyframes orbDrift1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    20% { transform: translate(-80px, 60px) scale(1.15); }
    50% { transform: translate(40px, -80px) scale(0.85); }
    80% { transform: translate(-50px, -30px) scale(1.1); }
}

@keyframes orbDrift2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    30% { transform: translate(70px, -50px) scale(1.2); }
    60% { transform: translate(-40px, 40px) scale(0.8); }
}

@keyframes orbDrift3 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(-60px, -40px) scale(1.1); }
    50% { transform: translate(50px, 30px) scale(0.9); }
    75% { transform: translate(20px, -60px) scale(1.05); }
}

/* --- Scan Line --- */
.bg-scan-line {
    position: fixed;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, var(--color-accent) 15%, var(--color-accent) 85%, transparent 100%);
    opacity: 0.06;
    pointer-events: none;
    z-index: 0;
    animation: scanMove 6s linear infinite;
}

@keyframes scanMove {
    0% { top: -2%; }
    100% { top: 102%; }
}

.hero__content {
    position: relative;
    text-align: center;
    max-width: 800px;
}

.hero__badge {
    display: inline-block;
    padding: 8px 20px;
    background: var(--color-accent-soft);
    border: 1px solid rgba(167, 139, 250, 0.15);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--color-accent);
    letter-spacing: 0.05em;
    margin-bottom: 32px;
}

.hero__title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 6.5vw, 5rem);
    font-weight: 700;
    line-height: 1.08;
    letter-spacing: -0.03em;
    color: var(--color-white);
    margin-bottom: 28px;
}

.hero__accent {
    background: linear-gradient(135deg, var(--color-accent) 0%, #c4b5fd 50%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero__sub {
    font-size: clamp(1rem, 1.8vw, 1.2rem);
    line-height: 1.7;
    color: var(--color-text-secondary);
    max-width: 580px;
    margin: 0 auto 40px;
}

.hero__actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero__scroll {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
}

.hero__scroll-line {
    width: 1px;
    height: 48px;
    background: linear-gradient(to bottom, var(--color-accent), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(0.6); }
    50% { opacity: 1; transform: scaleY(1); }
}

/* ============================================================
   SERVICES
   ============================================================ */
.services {
    padding: 140px 0;
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 72px;
}

.services__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.service-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    padding: 36px 32px;
    transition: all 0.4s var(--ease-out);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover {
    background: var(--color-bg-card-hover);
    border-color: var(--color-border-hover);
    transform: translateY(-4px);
}

.service-card:hover::before {
    opacity: 1;
}

.service-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    background: radial-gradient(300px circle at var(--glow-x, 50%) var(--glow-y, 50%), rgba(167, 139, 250, 0.06), transparent 60%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover::after {
    opacity: 1;
}

.service-card__icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-accent-soft);
    border-radius: 10px;
    margin-bottom: 24px;
    color: var(--color-accent);
}

.service-card__icon svg {
    width: 22px;
    height: 22px;
}

.service-card__title {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--color-white);
    margin-bottom: 12px;
}

.service-card__text {
    font-size: 0.9rem;
    line-height: 1.65;
    color: var(--color-text-secondary);
}

/* ============================================================
   ABOUT
   ============================================================ */
.about {
    padding: 140px 0;
    background: rgba(12, 12, 16, 0.85);
    position: relative;
    z-index: 1;
}

.about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-border), transparent);
}

.about__layout {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 80px;
    align-items: center;
}

.about__visual {
    position: relative;
}

.about__portrait {
    width: 100%;
    aspect-ratio: 4 / 5;
    background: var(--color-surface);
    border-radius: 20px;
    border: 1px solid var(--color-border);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.about__portrait-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.about__visual-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, var(--color-accent-glow), transparent 70%);
    filter: blur(60px);
    opacity: 0.5;
    pointer-events: none;
}

.about__lead {
    font-size: 1.15rem;
    line-height: 1.6;
    color: var(--color-text);
    margin-bottom: 20px;
    font-weight: 400;
}

.about__text {
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--color-text-secondary);
    margin-bottom: 16px;
}

.about__stats {
    display: flex;
    gap: 40px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--color-border);
}

.about__stat-value {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-accent);
    display: block;
    margin-bottom: 4px;
}

.about__stat-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact {
    padding: 140px 0;
    position: relative;
    z-index: 1;
}

.contact__layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 80px;
    align-items: start;
}

.contact__text {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--color-text-secondary);
    margin-bottom: 32px;
}

.contact__link {
    font-size: 1.1rem;
    color: var(--color-accent);
    font-weight: 500;
    transition: opacity 0.25s ease;
}

.contact__link:hover {
    opacity: 0.8;
}

/* Form */
.contact__form {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    padding: 40px;
}

.form-group {
    margin-bottom: 24px;
}

.form-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--color-text);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 10px;
    outline: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-input::placeholder {
    color: var(--color-text-muted);
}

.form-input:focus {
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent-soft);
}

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

.form-status {
    margin-top: 16px;
    font-size: 0.875rem;
    text-align: center;
    min-height: 24px;
}

.form-status--success {
    color: #4ade80;
}

.form-status--error {
    color: #f87171;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
    padding: 48px 0;
    border-top: 1px solid var(--color-border);
    position: relative;
    z-index: 1;
}

.footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 24px;
}

.footer__tagline {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    margin-top: 4px;
}

.footer__links {
    display: flex;
    gap: 28px;
}

.footer__links a {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    transition: color 0.25s ease;
}

.footer__links a:hover {
    color: var(--color-white);
}

.footer__copy {
    font-size: 0.78rem;
    color: var(--color-text-muted);
    width: 100%;
    text-align: center;
    margin-top: 16px;
    padding-top: 24px;
    border-top: 1px solid var(--color-border);
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
[data-animate] {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

[data-animate].is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .services__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about__layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .about__visual {
        max-width: 360px;
        margin: 0 auto;
    }

    .contact__layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }
}

@media (max-width: 768px) {
    :root {
        --nav-height: 64px;
    }

    .nav__links {
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        height: 100vh;
        background: var(--color-bg-elevated);
        border-left: 1px solid var(--color-border);
        flex-direction: column;
        justify-content: center;
        gap: 32px;
        padding: 40px;
        transform: translateX(100%);
        transition: transform 0.4s var(--ease-out);
        z-index: 999;
    }

    .nav__links.is-open {
        transform: translateX(0);
    }

    .nav__links a {
        font-size: 1.1rem;
    }

    .nav__toggle {
        display: flex;
        z-index: 1001;
    }

    .nav__cta {
        text-align: center;
    }

    .hero {
        padding: 100px 20px 60px;
        min-height: calc(100vh - 40px);
    }

    .hero__title {
        font-size: clamp(2.2rem, 8vw, 3.5rem);
    }

    .hero__actions {
        flex-direction: column;
        align-items: center;
    }

    .hero__actions .btn {
        width: 100%;
        max-width: 300px;
    }

    .services,
    .about,
    .contact {
        padding: 80px 0;
    }

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

    .section-header {
        margin-bottom: 48px;
    }

    .about__stats {
        gap: 24px;
    }

    .contact__form {
        padding: 28px 24px;
    }

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

    .footer__links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero__badge {
        font-size: 0.7rem;
        padding: 6px 14px;
    }

    .service-card {
        padding: 28px 24px;
    }
}

/* --- Selection --- */
::selection {
    background: var(--color-accent-soft);
    color: var(--color-white);
}

/* --- Scrollbar (Webkit) --- */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--color-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--color-text-muted);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-text-secondary);
}
