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

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --accent:     #ff5c5c;
    --accent-dim: rgba(255, 92, 92, 0.12);
    --bg:         #0a0a0a;
    --surface:    #111111;
    --surface-2:  #181818;
    --surface-3:  #1f1f1f;
    --border:     #1f1f1f;
    --border-2:   #2a2a2a;
    --text:       #ffffff;
    --muted:      #888888;
    --muted-2:    #555555;
}

html { 
    scroll-behavior: smooth;
    scroll-padding-top: 100px;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg);
    color: var(--text);
    min-height: 100vh;
    padding: 16px;
}

::selection {
    background-color: var(--accent);
    color: var(--text);
}

::-moz-selection {
    background-color: var(--accent);
    color: var(--text);
}

/* ── Scroll Animations ── */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar {
    animation: slideDown 0.8s ease-out;
}

.hero {
    animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

/* Typewriter Effect */
.typewriter {
    display: inline-block;
    min-width: 20px;
}

.cursor {
    display: inline-block;
    color: var(--accent);
    margin-left: 2px;
    font-weight: 300;
    font-size: 0.9em;
}

.cursor.blink {
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

#about .section-header {
    animation: fadeInUp 0.8s ease-out 0.4s backwards;
}

#about .about-content {
    animation: fadeInUp 0.8s ease-out 0.6s backwards;
}

#portfolio .section-header {
    animation: fadeInUp 0.8s ease-out 0.8s backwards;
}

#portfolio .portfolio-grid {
    animation: fadeInUp 0.8s ease-out 1s backwards;
}

#contact .section-header {
    animation: fadeInUp 0.8s ease-out 1.2s backwards;
}

#contact .contact-grid {
    animation: fadeInUp 0.8s ease-out 1.4s backwards;
}

.footer {
    animation: fadeInUp 0.8s ease-out 1.6s backwards;
}

/* ── Layout Wrapper ── */
.wrapper {
    max-width: 1024px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* ── Glass Card ── */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: border-color 0.25s;
}

/* ── Navbar ── */
.navbar {
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 16px;
    z-index: 1000;
    backdrop-filter: blur(12px);
    background: rgba(17, 17, 17, 0.7);
}

.navbar-brand .name {
    font-weight: 700;
    font-size: 15px;
    letter-spacing: -0.01em;
}

.navbar-brand .role {
    font-size: 11px;
    color: var(--muted);
    margin-top: 1px;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background-color: var(--text);
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

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

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.navbar-links {
    display: flex;
    gap: 4px;
}

.navbar-links a {
    color: var(--muted);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    padding: 7px 14px;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}

.navbar-links a:hover {
    background: var(--surface-3);
    color: var(--text);
}

.navbar-links a.active {
    background: var(--surface-3);
    color: var(--text);
}

/* ── Hero ── */
.hero {
    padding: 64px 44px;
}

.hero h1 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 18px;
}

.hero h1 .accent { color: var(--accent); }

.hero .subtitle {
    color: var(--muted);
    font-size: 15px;
    line-height: 1.7;
    max-width: 460px;
    margin-bottom: 34px;
}

.hero-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-primary {
    background-color: var(--accent);
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.15s;
    display: inline-block;
}

.btn-primary:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--surface-3);
    color: var(--text);
    border: 1px solid var(--border-2);
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, transform 0.15s;
    display: inline-block;
}

.btn-secondary:hover {
    background: #252525;
    transform: translateY(-1px);
}

/* ── About Me ── */
.about-content {
    padding: 32px 44px;
}

.about-text {
    color: var(--muted);
    font-size: 15px;
    line-height: 1.8;
    max-width: 700px;
}

/* ── Section Header ── */
.section-header {
    padding: 14px 20px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-header h3 {
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.01em;
    color: var(--accent);
}

#portfolio .section-header::before {
    display: none;
}

/* ── Portfolio Grid ── */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.portfolio-card {
    padding: 0;
    cursor: pointer;
    transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
    overflow: hidden;
}

.portfolio-card:hover {
    border-color: var(--border-2);
    transform: translateY(-3px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.portfolio-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: var(--surface-2);
    border-radius: 10px;
    margin-bottom: 0;
    position: relative;
    overflow: hidden;
    object-fit: cover;
    display: block;
}

.portfolio-card h4 {
    font-weight: 700;
    font-size: 13px;
    letter-spacing: -0.01em;
}

.portfolio-card p {
    font-size: 11px;
    color: var(--muted);
    margin-top: 5px;
    line-height: 1.55;
}

/* ── Kontakt ── */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.section-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--muted-2);
    font-weight: 700;
    margin-bottom: 14px;
}

.contact-item {
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 14px;
    transition: border-color 0.2s;
}

.contact-item:hover {
    border-color: var(--border-2);
}

.contact-icon {
    width: 38px;
    height: 38px;
    background: var(--surface-2);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 14px;
    flex-shrink: 0;
}

.contact-icon svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
    flex-shrink: 0;
}

.contact-icon .icon-youtube {
    width: 26px;
    height: 26px;
}

.contact-icon i {
    font-size: 18px;
}

.contact-platform {
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 2px;
}

.contact-value {
    font-size: 13px;
    font-weight: 600;
}

/* ── Form ── */
.form-section { }

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 14px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
}

.form-group:last-of-type { margin-bottom: 0; }

.form-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
    font-weight: 600;
}

.input-field {
    background: var(--surface-2);
    border: 1px solid var(--border-2);
    border-radius: 9px;
    padding: 12px 14px;
    width: 100%;
    outline: none;
    box-shadow: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    color: var(--text);
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    transition: border-color 0.2s;
}

.input-field::placeholder { color: var(--muted-2); }

.input-field:focus {
    border-color: var(--accent);
    outline: none;
    box-shadow: none;
}

textarea.input-field { resize: none; }

select.input-field {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23888' viewBox='0 0 16 16'%3E%3Cpath d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 38px;
    cursor: pointer;
}

select.input-field option {
    background: var(--surface-2);
    color: var(--text);
}

.btn-submit {
    width: 100%;
    background: transparent;
    color: var(--accent);
    border: 1px solid var(--accent);
    padding: 14px;
    border-radius: 10px;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    cursor: pointer;
    margin-top: 18px;
    transition: background 0.2s, color 0.2s, transform 0.15s;
}

.btn-submit:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-1px);
}

/* Netlify reCAPTCHA */
[data-netlify-recaptcha] {
    margin: 16px 0;
    display: flex;
    justify-content: flex-start;
}

/* ── Footer ── */
.footer {
    padding: 16px 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
    text-align: center;
}

.footer span { 
    color: var(--accent);
    font-size: 14px;
}

/* ── Responsive ── */

/* Mobile Styles (Default) */
@media (max-width: 599px) {
    body {
        padding: 12px;
    }

    .wrapper {
        gap: 20px;
    }

    /* Mobile Navigation */
    .hamburger {
        display: flex;
    }

    .navbar {
        padding: 10px 16px;
    }

    .navbar-links {
        position: fixed;
        top: 64px;
        left: 12px;
        right: 12px;
        flex-direction: column;
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 14px;
        padding: 12px;
        gap: 6px;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    }

    .navbar-links.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .navbar-links a {
        width: 100%;
        padding: 12px 16px;
        font-size: 14px;
    }

    /* Hero Section - Smaller text */
    .hero {
        padding: 36px 24px;
    }

    .hero h1 {
        font-size: 28px;
        line-height: 1.25;
        margin-bottom: 14px;
    }

    .hero .subtitle {
        font-size: 14px;
        margin-bottom: 24px;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .hero-buttons a {
        width: 100%;
        text-align: center;
    }

    /* About */
    .about-content {
        padding: 24px 20px;
    }

    .about-text {
        font-size: 14px;
    }

    /* Section Headers */
    .section-header {
        padding: 12px 16px;
    }

    /* Portfolio Grid */
    .portfolio-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    /* Contact Grid */
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .contact-item {
        padding: 14px 16px;
    }

    /* Form */
    .form-row {
        grid-template-columns: 1fr;
    }

    .input-field,
    .textarea-field {
        font-size: 14px;
    }

    /* Lightbox */
    .lightbox-content {
        max-width: 90vw;
        max-height: 80vh;
    }
}

/* Tablet and Small Desktop */
@media (min-width: 600px) and (max-width: 899px) {
    .hamburger {
        display: flex;
    }

    .navbar-links {
        position: fixed;
        top: 76px;
        left: 20px;
        right: 20px;
        flex-direction: column;
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 14px;
        padding: 12px;
        gap: 6px;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    }

    .navbar-links.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .navbar-links a {
        width: 100%;
        padding: 12px 16px;
        font-size: 14px;
    }

    .hero h1 {
        font-size: 42px;
    }
}

@media (min-width: 600px) {
    body { padding: 20px; }

    .form-row { grid-template-columns: 1fr 1fr; }

    .contact-grid {
        grid-template-columns: 5fr 8fr;
    }
}

@media (min-width: 900px) {
    body { padding: 28px; }

    .hero { padding: 72px 52px; }

    .hero h1 { font-size: 58px; }

    .portfolio-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ── Lightbox ── */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    justify-content: center;
    align-items: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease-out, background-color 0.3s ease-out;
}

.lightbox.active {
    display: flex;
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.95);
}

.lightbox-wrapper {
    position: relative;
    display: inline-block;
    transform: scale(0.8);
    opacity: 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}

.lightbox.active .lightbox-wrapper {
    transform: scale(1);
    opacity: 1;
}

.lightbox-content {
    max-width: 75vw;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 64px rgba(0, 0, 0, 0.8);
    display: block;
}

.lightbox-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: #fff;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.lightbox-close:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.lightbox-close svg {
    width: 18px;
    height: 18px;
}
