html {
    scroll-behavior: smooth;
}

body {
    color: #e2e8f0;
    font-family: system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 100px 20px 40px 20px;

    background-color: #0b0f19;
    background-image: 
        /* Tiny background stars */
        radial-gradient(1px 1px at 20px 30px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 75px 140px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 150px 60px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 220px 280px, #ffffff, rgba(0,0,0,0)),
        
        /* Medium foreground stars */
        radial-gradient(1.5px 1.5px at 40px 180px, #e2e8f0, rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 190px 45px, #e2e8f0, rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 290px 220px, #e2e8f0, rgba(0,0,0,0)),
        
        /* Scattered distant stars */
        radial-gradient(1px 1px at 100px 250px, #94a3b8, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 310px 90px, #94a3b8, rgba(0,0,0,0));

    background-size: 350px 350px;
}

.page-view {
    display: none;
}

.page-view.active {
    display: block;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(11, 15, 25, 0.85);
    backdrop-filter: blur(3px);
    border-bottom: 1px solid #1f2937;
    z-index: 1000;
}

.nav-container {
    max-width: 650px;
    margin: 0 auto;
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-weight: bold;
    font-size: 1.1rem;
    color: #38bdf8 !important;
    text-decoration: none;
    cursor: pointer;
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-links a {
    color: #6b7280;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s ease;
    cursor: pointer;
}

.nav-links a.active, .nav-links a:hover {
    color: #ba9ffb; 
}

section {
    max-width: 650px;
    margin: 0 auto 30px auto;
    padding: 30px;
    background-color: #111827;
    border: 1px solid #1f2937;
    border-radius: 12px;
}

h1 {
    color: #38bdf8;
    font-size: 2.5rem;
    margin-top: 0;
}

h2 {
    color: #ba9ffb;
    font-size: 1.75rem;
    border-bottom: 2px solid #334155;
    padding-bottom: 8px;
    margin-top: 0;
}

a {
    color: #38bdf8;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    text-decoration: underline;
}

.project-grid {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.project-card {
    background-color: #1f2937;
    padding: 24px;
    border-radius: 10px;
    border: 1px solid #374151;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover {
    transform: translateY(-4px); 
    box-shadow: 0 8px 20px -5px rgba(37, 94, 240, 0.577);
    border-color: #38bdf8;
}

.project-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
}

.card-media-group {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 15px;
    padding: 20px;
    background-color: #0b0f19;
    border: 1px dashed #4b5563;
    border-radius: 8px;
    box-sizing: border-box;
    justify-items: center;
}

.card-media-group img {
    width: 95%;
    height: auto;
    object-fit: cover;
    object-position: center;
    border-radius: 6px;
    display: block;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

@media (max-width: 600px) {
    .card-media-group img {
        width: 100%;
        height: 180px;
    }
}

.img-placeholder {
    color: #4b5563;
    font-size: 0.85rem;
    font-family: monospace;
    display: block;
    text-align: center;
    width: 100%;
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(11, 15, 25, 0.7);
    backdrop-filter: blur(12px);               
    z-index: 2000;                           
    display: flex;
    align-items: center;                     
    justify-content: center;                 
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.popup-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.popup-box {
    background-color: #111827;
    border: 1px solid #1f2937;
    border-radius: 12px;
    padding: 30px;
    max-width: 450px;
    width: 90%;
    position: relative;
    text-align: center;
}

.close-popup {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #6b7280;
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.2s ease;
}

.close-popup:hover {
    color: #ba9ffb;
}

.popup-box h3 {
    margin-top: 0;
    color: #38bdf8;
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.contact-info-grid {
    background-color: #0b0f19;
    border: 1px solid #1f2937;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    text-align: left;
}

.contact-row {
    margin-bottom: 15px;
}

.contact-row:last-child {
    margin-bottom: 0;
}

.coord-label {
    display: block;
    font-size: 0.75rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.coord-value {
    font-size: 1rem;
    font-family: monospace;
    color: #e2e8f0;
}

.coord-value a{
    color: #ba9ffb;
}

.coord-value a:hover {
    color: #38bdf8;
    text-decoration: underline;
}

.close-panel-btn {
    width: 100%;
    background-color: rgba(37, 94, 240, 0.1);
    color: #38bdf8;
    padding: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.close-panel-btn:hover {
    background-color: rgba(37, 94, 240, 0.2);
    border-color: #38bdf8;
}

.subsection-title {
    color: #ba9ffb;
    font-size: 1.3rem;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.project-video {
    width: 95%;
    height: auto;
    object-fit: cover;
    background-color: #000000;
    border-radius: 6px;
    display: block;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    outline: none;
}

@media (max-width: 600px) {
    .project-video {
        width: 100%;
        height: 180px;
    }
}