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

:root {
    --bg-dark: #09090b; /* Very dark zinc */
    --bento-bg: #18181b; /* Darker zinc for boxes */
    --bento-border: #27272a;
    --bento-hover: #202024;
    
    --gold-primary: #d4af37;
    --gold-light: #f3e5ab;
    --gold-gradient: linear-gradient(135deg, #bf953f, #fcf6ba, #b38728, #fbf5b7, #aa771c);
    
    --text-main: #f4f4f5;
    --text-muted: #a1a1aa;
    
    --font-sans: 'Outfit', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Grid settings */
    --grid-gap: 1.5rem;
    --box-padding: 2rem;
    --box-radius: 24px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Hide scrollbar for Chrome, Safari and Opera */
::-webkit-scrollbar {
    display: none;
}

/* Hide scrollbar for IE, Edge and Firefox */
html {
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Typography */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; }
.gold-text {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

/* Navigation */
.bento-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.logo-text {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--text-main);
}

/* Layout */
.bento-layout {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 5%;
}

.bento-section {
    margin-bottom: 6rem;
}

.section-title {
    font-size: 2.2rem;
    margin-bottom: 2rem;
    letter-spacing: -0.5px;
}

/* The Grid */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(180px, auto);
    gap: var(--grid-gap);
}

.col-span-1 { grid-column: span 1; }
.col-span-2 { grid-column: span 2; }
.col-span-3 { grid-column: span 3; }
.col-span-4 { grid-column: span 4; }
.row-span-1 { grid-row: span 1; }
.row-span-2 { grid-row: span 2; }

/* The Box */
.bento-box {
    background: var(--bento-bg);
    border: 1px solid var(--bento-border);
    border-radius: var(--box-radius);
    padding: var(--box-padding);
    display: flex;
    flex-direction: column;
    transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
    position: relative;
    overflow: hidden;
}

.bento-box:hover {
    transform: translateY(-4px);
    border-color: rgba(212, 175, 55, 0.3);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    background: var(--bento-hover);
}

/* Specific Boxes */
.intro-box {
    justify-content: center;
}

.greeting {
    font-size: 3.5rem;
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
}

.role {
    font-size: 1.4rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.bio {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
    max-width: 90%;
}

.intro-actions {
    display: flex;
    gap: 1rem;
}

.bento-btn {
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    display: inline-block;
}

.bento-btn.primary {
    background: var(--text-main);
    color: var(--bg-dark);
}

.bento-btn.primary:hover {
    background: var(--gold-primary);
}

.bento-btn.secondary {
    background: transparent;
    border: 1px solid var(--bento-border);
    color: var(--text-main);
}

.bento-btn.secondary:hover {
    border-color: var(--text-main);
}

/* Photo Box */
.photo-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--box-radius);
    position: absolute;
    top: 0; left: 0;
    transition: transform 0.5s;
}

.photo-box:hover img {
    transform: scale(1.05);
}

.socials-box {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 1rem;
    padding: 1.5rem;
}

.socials-box .social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--bento-border);
    border-radius: 16px;
    color: var(--text-main);
    font-size: 1.5rem;
    transition: var(--transition);
    text-decoration: none;
}

.socials-box .social-icon:hover {
    background: var(--gold-primary);
    color: var(--bg-dark);
    border-color: var(--gold-primary);
}

/* Availability Box */
.availability-box {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    text-align: left;
}

.status-indicator {
    position: relative;
    width: 16px;
    height: 16px;
}

.status-dot {
    width: 16px;
    height: 16px;
    background-color: #22c55e;
    border-radius: 50%;
    position: absolute;
    top: 0; left: 0;
}

.status-dot::after {
    content: '';
    position: absolute;
    top: -4px; left: -4px; right: -4px; bottom: -4px;
    background-color: rgba(34, 197, 94, 0.4);
    border-radius: 50%;
    animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
    0% { transform: scale(0.8); opacity: 1; }
    100% { transform: scale(2); opacity: 0; }
}

.availability-box h3 { font-size: 1.1rem; }
.availability-box p { color: var(--text-muted); font-size: 0.9rem; }

/* Experience Box */
.exp-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.exp-header i { font-size: 1.8rem; }
.exp-box h3 { font-size: 1.5rem; }
.exp-box .company { color: var(--gold-light); font-size: 1rem; margin-bottom: 1.5rem; }

.exp-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.exp-list li {
    position: relative;
    padding-left: 1.5rem;
    color: var(--text-muted);
}

.exp-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--gold-primary);
}

/* Cert Boxes */
.cert-box {
    align-items: center;
    justify-content: center;
    text-align: center;
}
.cert-box i { font-size: 3rem; margin-bottom: 1rem; }
.cert-box h3 { font-size: 1.2rem; margin-bottom: 0.25rem; }
.cert-box p { color: var(--text-muted); font-size: 0.9rem; }

/* Code Box */
.code-box {
    padding: 0;
    background: #0d0d0f;
}

.window-header {
    background: #18181b;
    padding: 1rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--bento-border);
}

.dot { width: 12px; height: 12px; border-radius: 50%; margin-right: 8px; }
.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }

.window-title { margin-left: 10px; color: var(--text-muted); font-family: var(--font-mono); font-size: 0.9rem; }

.window-body {
    padding: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: #e4e4e7;
    overflow-x: auto;
}

.keyword { color: var(--gold-primary); }
.function { color: var(--gold-light); }
.comment { color: #71717a; }
.string { color: #a1a1aa; }

/* Project Boxes */
.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
}

.project-box h3 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.project-box p { color: var(--text-muted); margin-bottom: 1.5rem; font-size: 0.95rem; flex-grow: 1; }

.project-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.project-list li {
    position: relative;
    padding-left: 1.2rem;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.project-list li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: var(--gold-primary);
}

.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: auto; }
.tag {
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold-light);
    border: 1px solid rgba(212, 175, 55, 0.2);
}

/* Blog Boxes */
.blog-box h3 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.blog-box p { color: var(--text-muted); margin-bottom: 1.5rem; font-size: 0.95rem; }
.read-more {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
    transition: var(--transition);
}
.read-more:hover { color: var(--gold-primary); gap: 0.8rem; }

/* Skills Box */
.skills-box {
    justify-content: center;
}

.skills-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--bento-border);
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.95rem;
}

.skill-item i { color: var(--gold-primary); }

/* Footer */
.bento-footer {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
    border-top: 1px solid var(--bento-border);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Grid */
@media (max-width: 900px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .col-span-4 { grid-column: span 2; }
    .nav-links { display: none; }
    .greeting { font-size: 2.8rem; }
    .bio { max-width: 100%; }
}

@media (max-width: 600px) {
    .bento-grid {
        grid-template-columns: 1fr;
    }
    .col-span-2, .col-span-3, .col-span-4 { grid-column: span 1; }
    .row-span-2 { grid-row: auto; }
    .intro-box { text-align: center; }
    .intro-actions { justify-content: center; }
    .photo-box { height: 350px; }
    
    /* Fix inline flex row layouts on small screens */
    .bento-box[style*="flex-direction: row"], 
    .bento-box[style*="justify-content: space-between"] {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 1rem !important;
    }
    .bento-box[style*="justify-content: space-between"] > div {
        text-align: left !important;
    }
    .tags[style*="justify-content: flex-end"] {
        justify-content: flex-start !important;
    }
}

/* Terminal Modal UI */
.terminal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.terminal-window-ui {
    width: 90%;
    max-width: 800px;
    height: 70vh;
    background: #0d0d0f;
    border-radius: 12px;
    border: 1px solid var(--bento-border);
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    overflow: hidden;
    animation: term-slide-up 0.3s ease-out;
}

@keyframes term-slide-up {
    from { opacity: 0; transform: translateY(50px); }
    to { opacity: 1; transform: translateY(0); }
}

.terminal-header-ui {
    background: #18181b;
    padding: 1rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--bento-border);
    position: relative;
}

.terminal-buttons-ui {
    display: flex;
    gap: 8px;
    position: absolute;
    left: 1rem;
}

.terminal-btn-ui {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    cursor: pointer;
}
.terminal-btn-ui.close { background: #ff5f56; }
.terminal-btn-ui.close:hover { opacity: 0.8; }
.terminal-btn-ui.min { background: #ffbd2e; cursor: default; }
.terminal-btn-ui.max { background: #27c93f; cursor: default; }

.terminal-title-ui {
    margin: 0 auto;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.terminal-body-ui {
    flex-grow: 1;
    padding: 1.5rem;
    font-family: var(--font-mono);
    font-size: 1rem;
    color: #e4e4e7;
    overflow-y: auto;
    cursor: text;
}

.terminal-output {
    margin-bottom: 0.5rem;
}

.cmd-response {
    color: var(--text-muted);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.terminal-input-line {
    display: flex;
    align-items: center;
}

.prompt {
    color: #22c55e;
    margin-right: 0.5rem;
    white-space: nowrap;
}

#terminal-input {
    background: transparent;
    border: none;
    color: #e4e4e7;
    font-family: var(--font-mono);
    font-size: 1rem;
    flex-grow: 1;
    outline: none;
}

/* Filter Bar */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-bottom: 2.5rem;
}

.filter-btn {
    background: var(--bento-bg);
    border: 1px solid var(--bento-border);
    color: var(--text-muted);
    padding: 0.6rem 1.2rem;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover {
    border-color: var(--gold-primary);
    color: var(--text-main);
}

.filter-btn.active {
    background: var(--gold-primary);
    color: var(--bg-dark);
    border-color: var(--gold-primary);
}

/* Article filtering animation */
.bento-box.hidden {
    display: none !important;
}
