/* ============================================
   CUSTOM STYLES — Ngurah Arya Wira Portfolio
   Theme: Clean White & Blue Minimalist
============================================ */

/* --- Base --- */
*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: #ffffff;
    color: #0f172a;
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #93c5fd; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #2563eb; }

/* --- Navbar --- */
#navbar {
    transition: all 0.4s ease;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.05);
}

/* --- Section Label --- */
.section-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #2563eb;
    margin-bottom: 12px;
}

.section-label::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 2px;
    background: #2563eb;
    border-radius: 99px;
}

/* --- Reveal Animations --- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}

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

.reveal-left {
    opacity: 0;
    transform: translateX(-24px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(24px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* --- Card Base --- */
.card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    transition: all 0.3s ease;
}

.card:hover {
    border-color: #93c5fd;
    box-shadow: 0 8px 30px rgba(37, 99, 235, 0.08);
    transform: translateY(-3px);
}

/* --- Blue Card Accent --- */
.card-blue {
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    border: 1px solid #bfdbfe;
    border-radius: 16px;
}

/* --- Tech Badge --- */
.tech-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 99px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1d4ed8;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    transition: all 0.2s ease;
}

.tech-badge:hover {
    background: #dbeafe;
    border-color: #93c5fd;
}

/* --- Type Badge --- */
.type-badge {
    padding: 2px 10px;
    border-radius: 99px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    background: #eff6ff;
    color: #2563eb;
    border: 1px solid #bfdbfe;
}

.type-badge.research  { background: #f0fdf4; color: #15803d; border-color: #86efac; }
.type-badge.publication { background: #faf5ff; color: #7c3aed; border-color: #c4b5fd; }
.type-badge.web-app  { background: #eff6ff; color: #2563eb; border-color: #bfdbfe; }
.type-badge.data-science { background: #fff7ed; color: #c2410c; border-color: #fdba74; }
.type-badge.machine-learning { background: #fdf2f8; color: #9d174d; border-color: #f9a8d4; }

/* --- Skill Bar --- */
.skill-track {
    height: 4px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    background: linear-gradient(90deg, #2563eb, #60a5fa);
    border-radius: 99px;
    width: 0%;
    transition: width 1.4s cubic-bezier(0.23, 1, 0.32, 1);
}

/* --- Filter Tab --- */
.filter-tab {
    padding: 9px 22px;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    color: #64748b;
    border: 1px solid transparent;
    background: transparent;
}

.filter-tab.active {
    background: #2563eb;
    color: #ffffff;
    border-color: #2563eb;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.filter-tab:not(.active):hover {
    color: #2563eb;
    background: #eff6ff;
    border-color: #bfdbfe;
}

/* --- Design category badge --- */
.cat-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 99px;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.cat-badge-instagram { background: #fdf2f8; color: #9d174d; border: 1px solid #f9a8d4; }
.cat-badge-client    { background: #f0fdf4; color: #15803d; border: 1px solid #86efac; }
.cat-badge-personal  { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }

/* --- Porto Card Image --- */
.porto-card-img {
    width: 100%;
    height: 210px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.porto-card:hover .porto-card-img {
    transform: scale(1.04);
}

/* --- Profile Avatar Border --- */
.avatar-border {
    padding: 3px;
    background: linear-gradient(135deg, #2563eb, #60a5fa, #93c5fd);
    border-radius: 9999px;
}

/* --- Blue Dot Line Separator --- */
.dot-line {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #94a3b8;
    font-size: 0.85rem;
}

.dot-line::before, .dot-line::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

/* --- Experience Timeline Line --- */
.timeline-line {
    position: relative;
    padding-left: 20px;
}

.timeline-line::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, #2563eb, #bfdbfe, transparent);
}

.timeline-dot {
    position: absolute;
    left: -4px;
    top: 8px;
    width: 10px;
    height: 10px;
    background: #2563eb;
    border-radius: 50%;
    border: 2px solid #ffffff;
    box-shadow: 0 0 0 3px #bfdbfe;
}

/* --- Hamburger --- */
#mobile-menu-btn span {
    display: block;
    width: 20px;
    height: 2px;
    background: #334155;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

#mobile-menu-btn.open span:nth-child(1) {
    transform: rotate(45deg) translate(2px, 2px);
}

#mobile-menu-btn.open span:nth-child(2) { opacity: 0; }

#mobile-menu-btn.open span:nth-child(3) {
    transform: rotate(-45deg) translate(2px, -2px);
}

/* --- Stat Number --- */
.stat-number {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 2rem;
    color: #2563eb;
    line-height: 1;
}

/* --- Form Input --- */
.form-input {
    width: 100%;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 0.875rem;
    color: #0f172a;
    transition: all 0.2s ease;
    outline: none;
}

.form-input:focus {
    border-color: #60a5fa;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.form-input::placeholder { color: #94a3b8; }

/* --- Button Primary --- */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: #2563eb;
    color: #ffffff;
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 10px;
    transition: all 0.25s ease;
    border: none;
    cursor: pointer;
    text-decoration: none;
}

.btn-primary:hover {
    background: #1d4ed8;
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.3);
    transform: translateY(-1px);
}

/* --- Button Outline --- */
.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: transparent;
    color: #2563eb;
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 10px;
    border: 1.5px solid #2563eb;
    transition: all 0.25s ease;
    cursor: pointer;
    text-decoration: none;
}

.btn-outline:hover {
    background: #eff6ff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
    transform: translateY(-1px);
}

/* --- Section BG Variants --- */
.bg-section { background: #f8fafc; }

/* --- Typewriter --- */
.typewriter-cursor {
    display: inline-block;
    width: 2px;
    height: 0.9em;
    background: #2563eb;
    margin-left: 2px;
    vertical-align: middle;
    border-radius: 2px;
    animation: blink 1s step-end infinite;
}

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

/* --- Float Animation --- */
@keyframes float-slow {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.float-slow { animation: float-slow 5s ease-in-out infinite; }

/* --- Portfolio Item Transition --- */
.porto-item {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* --- Divider --- */
.divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0;
}

/* --- Blue Accent Dot --- */
.blue-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    background: #2563eb;
    border-radius: 50%;
    flex-shrink: 0;
}

/* --- Hover Card Link --- */
.hover-card-link:hover { text-decoration: none; }

/* --- Available badge --- */
.available-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #15803d;
}

/* --- Pulse Green --- */
.pulse-green {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    animation: pulse-anim 2s ease-in-out infinite;
}

@keyframes pulse-anim {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.3); }
}

/* --- Responsive adjustments --- */
@media (max-width: 640px) {
    .btn-primary, .btn-outline { width: 100%; justify-content: center; }
}
