/* Root variables (theme) */
:root {
    --bg: #0b0f14;
    --card: rgba(255, 255, 255, 0.1);
    --muted: rgba(255, 255, 255, 0.5);
    --text: #e6eef7;
    --accent: rgba(255, 255, 255, 0.65);
    --accent2: #6dd3ff;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(0,0,0,0.35);
}

html {
    scroll-behavior: smooth;
    margin: 0;
}

/* Global reset */
* { box-sizing: border-box; }
body {

    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Inter;
    color: var(--text);
}

/* Glass effect */
.glass {
    background: rgba(255,255,255,0.08); /* more transparent */
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: var(--radius);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow);
    padding: 32px;
    margin: 24px auto;
    width: min(1000px, 92vw);
}

/* Hero */
.hero {
    text-align: center;
    padding: 120px 20px;
}

.hero h1 {
    font-size: clamp(32px, 5vw, 60px);
}

.hero p {
    color: var(--muted);
    font-size: clamp(16px, 2.5vw, 22px);
    max-width: 700px;
    margin: 0 auto;
}

/* Button */
.button {
    display: inline-block;
    margin-top: 20px;
    padding: 14px 26px;
    border-radius: 12px;
    font-weight: 600;
    color: var(--text);
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(8px);
    cursor: pointer;
    text-decoration: none;
    transition: transform .05s;
}

.button:hover { filter: brightness(1.08); }
.button:active { transform: translateY(1px); }

/* Section wrapper */
.section {
    margin: 40px auto;
    width: min(900px, 92vw);
    padding: 20px;
}

.section h2 {
    margin-bottom: 12px;
    font-size: 28px;
    text-align: center;
}

/* Top hero sitting directly on background */
.hero-plain {
    text-align: center;
    margin-top: -5px;
}

.hero-plain h1 {
    font-size: clamp(34px, 5vw, 60px);
    margin-bottom: -10px;
}

.hero-plain p {
    color: var(--muted);
    font-size: clamp(15px, 2.2vw, 20px);
}

/* Skills filter bar (not glass) */
.skills-bar {
    width: min(1000px, 92vw);
    margin: 0 auto 5px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    padding: 0 10px;
}

.skill-divider {
    color: rgba(255,255,255,0.5);
    margin: 5px;
    font-weight: 300;
    user-select: none;
}

.skill-pill {
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 13px;
    border: 1px solid rgba(255,255,255,0.35);
    background: rgba(0, 0, 0, 0.25);
    cursor: pointer;
    user-select: none;
    transition: background .15s, transform .05s, border-color .15s;
}

.skill-pill:hover {
    background: rgba(255,255,255,0.12);
}

.skill-pill--active {
    background: rgba(255,255,255,0.22);
    border-color: rgba(255,255,255,0.8);
}

/* Projects inside the glass pane */
.projects-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.project-card {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid rgba(255,255,255,0.06);
    display: flex;
    align-items: center;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 0; /* instead of negative margin */
}

.project-title-block {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    margin-bottom: 8px; /* consistent padding below date */
}

.project-date {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.55);  /* softer grey */
    margin-top: 3px;
    padding: 0;
}

.project-image {
    width: 33%;
    height: 225px;
    object-fit: contain;
    object-position: center;  /* keep subject centred */
    border-radius: 12px;
    flex-shrink: 0;
}

.project-info {
    flex: 1;
    margin-left: 20px;
    margin-bottom: -5px;
}

.project-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;   /* resets both top AND bottom margin */
    padding: 0;
}

.project-skills {
    display: flex;
    flex-wrap: wrap;
    font-size: 11px;
    margin-top: 10px;
    margin-bottom: 5px;
    gap: 5px;
}

.project-skill-tag {
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.25);
    background: rgba(0,0,0,0.35);
}

.project-description {
    font-size: 14px;
    color: var(--muted);
    line-height: 1.3;
    white-space: normal;
}

.project-link-small {
    display: inline-block;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 500;
    border-radius: 6px;
    color: var(--text);
    text-decoration: none;
    align-self: flex-start;  /* aligns with title top */
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(6px);
    margin-top: 1px;
    transition: all .15s ease;
}

.project-link-small:hover {
    filter: brightness(1.10);
}

.project-link-small:active {
    transform: translateY(1px);
}

/* LIGHTBOX OVERLAY */
#lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;

    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(4px);

    display: flex;
    align-items: center;
    justify-content: center;

    visibility: hidden;
    opacity: 0;
    transition: opacity .25s ease, visibility .25s ease;

    z-index: 9999;
}

#lightbox-overlay.visible {
    visibility: visible;
    opacity: 1;
}

#lightbox-image {
    max-width: 90%;
    max-height: 90%;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

/* CLOSE BUTTON */
#lightbox-close {
    position: absolute;
    top: 20px;
    right: 55px;
    font-size: 48px;
    color: white;
    cursor: pointer;
    font-weight: 300;
    transition: 0.2s ease;
}

#lightbox-close:hover {
    color: #ccc;
}

/* ===== APP PAGE ===== */

.app-hero {
    text-align: center;
    margin-top: 60px;
    margin-bottom: 40px;
}

.app-subtitle {
    font-size: 18px;
    color: rgba(255,255,255,0.6);
    margin-bottom: 4px;
}

.app-title {
    font-size: clamp(28px, 4vw, 48px);
    margin-top: 0;
    margin-bottom: 0;
}

.app-section-title {
    text-align: center;
    margin-top: 10px;     /* reduce gap above */
    font-size: 26px;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    margin-top: 35px;
}

.feature-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.feature-card h3 {
    margin: 0;
    font-size: 20px;
}

.feature-card p {
    margin: 0;
    color: var(--muted);
}

.feature-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 12px;
    margin-top: 10px;
}

.external-profile-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 9999;

    display: flex;
    flex-direction: column;   /* STACK VERTICALLY */
    gap: 0px;                /* space between icons */
}

.external-profile-btn {
    z-index: 9999;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;

    transition: all 0.2s ease;
}

.external-profile-btn img {
    width: 22px;
    height: auto;
}

.external-profile-btn:hover {
    filter: brightness(1.15);
    transform: translateY(-2px);
}

