:root {
    --color-status: #31b417;
    --color-github: #652ea4;
    --color-linkedin: #0a66c2;
    --color-filecodec: #e74c3c;

    --glass-material: rgba(30, 30, 30, 0.24);
    --glass-blur: 20px;
    --border-color: rgba(255, 255, 255, 0.1);

    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.6);
    --accent-hover: rgba(255, 255, 255, 0.15);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-primary);
    height: 100vh;
    overflow: hidden;
    background-color: #111;
}

.background-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    background-color: #0f172a;
    transition: background-color 1s ease;
}

.background-layer.day {
    background-color: #e2e8f0;
}

.background-layer.day .blob-1 {
    background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
}

.background-layer.day .blob-2 {
    background: radial-gradient(circle, #0ea5e9 0%, transparent 70%);
}

.background-layer.day .blob-3 {
    background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
}

.background-layer.night {
    background-color: #020617;
}

.background-layer.night .blob-1 {
    background: radial-gradient(circle, #1e1b4b 0%, transparent 70%);
}

.background-layer.night .blob-2 {
    background: radial-gradient(circle, #312e81 0%, transparent 70%);
}

.background-layer.night .blob-3 {
    background: radial-gradient(circle, #0f172a 0%, transparent 70%);
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    animation: float 20s infinite alternate ease-in-out;
    transition: background 1s ease;
}

.blob-1 {
    width: 60vw;
    height: 60vw;
    top: -10vw;
    left: -10vw;
    animation-delay: 0s;
}

.blob-2 {
    width: 50vw;
    height: 50vw;
    bottom: -10vw;
    right: -10vw;
    animation-delay: -5s;
}

.blob-3 {
    width: 70vw;
    height: 70vw;
    top: 20vh;
    left: 30vw;
    animation-delay: -10s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(10vw, 5vh) scale(1.1);
    }

    66% {
        transform: translate(-5vw, 15vh) scale(0.9);
    }

    100% {
        transform: translate(-10vw, -5vh) scale(1.05);
    }
}

.noise-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.04;
    pointer-events: none;
    z-index: 1;
}

.theme-toggle-container {
    position: absolute;
    top: 30px;
    right: 40px;
    z-index: 100;
}

.theme-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 30px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    transition: .4s;
    border-radius: 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 7px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 4px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
    z-index: 2;
}

input:checked+.slider:before {
    transform: translateX(30px);
}

.icon-sun,
.icon-moon {
    font-size: 14px;
    color: var(--text-secondary);
    z-index: 1;
}

.icon-sun {
    margin-right: auto;
}

.icon-moon {
    margin-left: auto;
}

.app-layout {
    display: flex;
    height: 100vh;
    width: 100%;
}

.sidebar {
    width: 280px;
    height: 100%;

    background: var(--glass-material);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));

    display: flex;
    flex-direction: column;
    padding: 40px 30px;
    border-right: 1px solid var(--border-color);
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 60px;
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 1.1rem;
    font-weight: 500;
    padding: 12px 15px;
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}


.nav-item:hover {
    color: white;
    transform: translateX(5px);
    background-color: var(--accent-hover);
}

.nav-item.filecodec:hover {
    background-color: var(--color-filecodec);
    box-shadow: 0 0 20px rgba(231, 76, 60, 0.4);
}

.nav-item.linkedin:hover {
    background-color: var(--color-linkedin);
    box-shadow: 0 0 20px rgba(10, 102, 194, 0.4);
}

.nav-item.status:hover {
    background-color: var(--color-status);
    box-shadow: 0 0 20px rgba(67, 80, 255, 0.4);
}

.nav-item.github:hover {
    background-color: var(--color-github);
    box-shadow: 0 0 20px rgba(46, 164, 79, 0.4);
}

.nav-item i {
    width: 24px;
    text-align: center;
}

.dashboard-container {
    flex: 1;
    display: grid;
    grid-template-columns: 280px minmax(0, 800px);
    grid-template-rows: 1fr auto;
    grid-template-areas:
        "tech main"
        "tech github";
    gap: 20px;
    padding: 30px 40px;
    overflow: hidden;
    height: 100vh;
    justify-content: center;
}

.glass-card {
    background: var(--glass-material);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.tech-stack-card {
    grid-area: tech;
    justify-content: flex-start;
}

.card-main {
    grid-area: main;
    justify-content: space-between;
    padding: 50px;
}

.github-widget-card {
    grid-area: github;
}

.info-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: auto;
}

.header-section {
    text-align: center;
    margin-bottom: 20px;
}

#clock {
    font-family: 'Inter', sans-serif;
    font-size: 8rem;
    font-weight: 400;
    letter-spacing: -2px;
    line-height: 1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.calendar-wrapper {
    flex: 1;
    max-width: 350px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 1.2rem;
    font-weight: 600;
}

.cal-controls i {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-left: 15px;
    cursor: pointer;
    transition: color 0.2s;
}

.cal-controls i:hover {
    color: white;
}

.weekdays-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
    font-weight: 600;
}

.days-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
}

.cal-day {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.cal-day.today {
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.cal-day.empty {
    pointer-events: none;
}

.weather-wrapper {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.weather-main {
    font-size: 4rem;
    font-weight: 400;
    line-height: 1;
}

.weather-icon-box {
    font-size: 3rem;
    color: #fff;
}

#full-date {
    margin-top: 10px;
    font-size: 1rem;
    color: var(--text-secondary);
}

@media (max-width: 1000px) {

    .theme-toggle-container {
        top: 22px;
        right: 15px;
    }

    .app-layout {
        flex-direction: column;
        overflow-y: auto;
    }

    .sidebar {
        width: 100%;
        height: auto;
        padding: 20px;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        position: relative;
    }

    .logo {
        margin: 0;
        font-size: 1.5rem;
    }

    .nav-menu {
        flex-direction: row;
        gap: 8px;
        align-items: center;
        margin-right: 60px;
    }

    .nav-item {
        padding: 10px;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .nav-item span {
        display: none;
    }

    .nav-item:hover {
        transform: none;
    }

    .dashboard-container {
        display: flex;
        flex-direction: column;
        height: auto;
        padding: 20px;
        gap: 15px;
        overflow-y: auto;
    }

    .glass-card {
        padding: 20px;
    }

    #clock {
        font-size: 3rem;
    }

    .info-section {
        flex-direction: column-reverse;
        gap: 30px;
        align-items: center;
    }

    .weather-wrapper {
        text-align: center;
        align-items: center;
        width: 100%;
    }

    .calendar-wrapper {
        width: 100%;
    }
}

/* GitHub Widget */
.github-widget-card:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.08);
}

.widget-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.chart-container {
    width: 100%;
    display: flex;
    justify-content: center;
    overflow: hidden;
}

.chart-container img {
    width: 100%;
    height: auto;
    object-fit: contain;
    opacity: 0.9;
}


/* ===== Stagger Entry Animations ===== */
.stagger-in {
    opacity: 0;
    transform: translateY(30px);
    animation: stagger-fade-in 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: calc(var(--stagger, 0) * 0.15s + 0.2s);
}

body.loading .stagger-in {
    opacity: 0;
    transform: translateY(30px);
}

@keyframes stagger-fade-in {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Tech Stack Card ===== */
.tech-stack-card {
    min-height: auto !important;
    padding: 30px !important;
}

.tech-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tech-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    cursor: default;
}

.tech-chip:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.tech-chip i {
    font-size: 1rem;
    width: 18px;
    text-align: center;
}

.tech-chip:hover .fa-python {
    color: #3776ab;
}

.tech-chip:hover .fa-java {
    color: #f89820;
}

.tech-chip:hover .fa-golang {
    color: #00add8;
}

.tech-chip:hover .fa-c {
    color: #a8b9cc;
}

.tech-chip:hover .fa-js {
    color: #f7df1e;
}

.tech-chip:hover .fa-html5 {
    color: #e34f26;
}

.tech-chip:hover .fa-css3-alt {
    color: #1572b6;
}

.tech-chip:hover .fa-database {
    color: #4479a1;
}

.tech-chip:hover .fa-docker {
    color: #2496ed;
}

.tech-chip:hover .fa-linux {
    color: #fcc624;
}

.tech-chip:hover .fa-git-alt {
    color: #f05032;
}

.tech-chip:hover .fa-android {
    color: #78c257;
}

.tech-chip:hover .fa-microchip {
    color: #00c9a7;
}

@media (max-width: 1000px) {
    .tech-stack-card {
        padding: 20px !important;
    }

    .tech-chip {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
}