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

:root {
    /* Modern Color Palette */
    --bg-base: #fafcff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    
    --accent-light: #e0e7ff;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --secondary: #6366f1;
    --tertiary: #a855f7;
    
    /* Status Colors / Sinta */
    --sinta1: #ef4444;
    --sinta2: #f97316;
    --sinta3: #eab308;
    --sinta4: #22c55e;
    --sinta5: #06b6d4;
    --sinta6: #8b5cf6;
    --scopus: #e11d48;
    --doaj: #0d9488;
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary), var(--secondary));
    --gradient-text: linear-gradient(to right, var(--primary), var(--tertiary));
    
    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.65);
    --glass-border: rgba(255, 255, 255, 0.8);
    --glass-shadow: 0 8px 32px rgba(15, 23, 42, 0.05);

    /* Layout & Utilities */
    --radius-sm: 12px;
    --radius-md: 20px;
    --radius-lg: 32px;
    --radius-full: 9999px;
    
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   Resets & Base
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-primary);
    background-color: var(--bg-base);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

/* Dynamic Mesh Background */
.mesh-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    background: #fafcff;
}

.mesh-blob {
    position: absolute;
    filter: blur(90px);
    opacity: 0.4;
    border-radius: 50%;
    animation: drift 20s infinite alternate ease-in-out;
}

.blob-1 {
    top: -10%; left: -10%;
    width: 600px; height: 600px;
    background: #3b82f6;
    animation-duration: 25s;
}

.blob-2 {
    top: 20%; right: -10%;
    width: 500px; height: 500px;
    background: #a855f7;
    animation-delay: -5s;
    animation-duration: 30s;
}

.blob-3 {
    bottom: -20%; left: 30%;
    width: 700px; height: 700px;
    background: #6366f1;
    animation-delay: -10s;
    animation-duration: 22s;
}

@keyframes drift {
    0% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(50px, -50px) scale(1.1); }
    66% { transform: translate(-30px, 30px) scale(0.9); }
    100% { transform: translate(0, 0) scale(1); }
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    line-height: 1.2;
    color: var(--text-primary);
}

.text-gradient {
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

.container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(255,255,255,0), rgba(255,255,255,0.2), rgba(255,255,255,0));
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover:after {
    transform: translateX(100%);
}

.btn-glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.btn-glass:hover {
    background: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

/* ==========================================================================
   Navbar (Floating Pill)
   ========================================================================== */
.navbar {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    z-index: 100;
    transition: var(--transition-smooth);
}

.navbar-inner {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--glass-shadow);
}

.navbar.scrolled .navbar-inner {
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.3);
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--text-primary);
    line-height: 1;
}

.logo-subtitle {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.nav-menu {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    gap: 8px;
    list-style: none;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: var(--radius-full);
    transition: var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
    background: var(--accent-light);
    color: var(--primary);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.search-wrap i {
    position: absolute;
    left: 16px;
    color: var(--text-muted);
}

.search-wrap input {
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 10px 16px 10px 42px;
    border-radius: var(--radius-full);
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    width: 200px;
    transition: var(--transition-smooth);
}

.search-wrap input:focus {
    outline: none;
    background: white;
    width: 260px;
    border-color: var(--accent-light);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-primary);
    cursor: pointer;
}

/* ==========================================================================
   Hero Section (Modern Split Layout)
   ========================================================================== */
.hero {
    min-height: 100vh;
    padding-top: 140px;
    padding-bottom: 60px;
    display: flex;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 60px;
    align-items: center;
}

.hero-content {
    animation: fadeUp 1s ease-out forwards;
}

.pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    border: 1px solid var(--accent-light);
    padding: 6px 16px;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 24px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

.live-dot {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary);
    animation: pulse 2s infinite;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -1px;
    margin-bottom: 20px;
}

.hero-desc {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 500px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    gap: 16px;
}

/* Hero Bento Box Visual */
.hero-visual {
    position: relative;
    animation: fadeLeft 1s ease-out forwards;
}

.hero-bento {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 240px 180px;
    gap: 20px;
    position: relative;
}

.bento-item {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--glass-shadow);
    overflow: hidden;
    position: relative;
    transition: var(--transition-smooth);
}

.bento-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.bento-main {
    grid-column: 1 / -1;
    padding: 0;
}

.bento-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.bento-item:hover img {
    transform: scale(1.05);
}

.bento-main-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.8), transparent);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
    color: white;
}

.bento-main-overlay h3 {
    color: white;
    font-size: 1.5rem;
}

.bento-stat {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 24px;
}

.bento-stat .stat-val {
    font-family: 'Outfit', sans-serif;
    font-size: 3rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    margin-bottom: 8px;
}

.bento-stat .stat-label {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.bento-stat.accent {
    background: var(--gradient-primary);
    color: white;
}

.bento-stat.accent .stat-val, 
.bento-stat.accent .stat-label {
    color: white;
}

/* ==========================================================================
   Analytics Section (Bento Grid)
   ========================================================================== */
.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.section-header p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-top: 12px;
}

.analytics-section {
    padding: 80px 0;
}

.analytics-bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(140px, auto);
    gap: 24px;
}

.a-bento {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    transition: var(--transition-smooth);
}

.a-bento:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

/* Sinta Stats span 1 col */
.stat-sinta {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.sinta-head {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-family: 'Outfit';
    font-size: 1.1rem;
}

.sinta-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.s1 { background: var(--sinta1); }
.s2 { background: var(--sinta2); }
.s3 { background: var(--sinta3); }
.s4 { background: var(--sinta4); }
.s5 { background: var(--sinta5); }
.s6 { background: var(--sinta6); }

.sinta-val {
    font-size: 3rem;
    font-weight: 800;
    font-family: 'Outfit';
    margin-top: 16px;
}

/* Charts span larger areas */
.chart-wide {
    grid-column: span 2;
    grid-row: span 2;
    display: flex;
    flex-direction: column;
}

.chart-square {
    grid-column: span 2;
    grid-row: span 2;
    display: flex;
    flex-direction: column;
}

.bento-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.bento-header h3 {
    font-size: 1.2rem;
    font-weight: 700;
}

.canvas-wrap {
    flex: 1;
    position: relative;
    min-height: 220px;
}

/* ==========================================================================
   Journals Section
   ========================================================================== */
.journals-section {
    padding: 80px 0;
}

.filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 20px;
}

.filter-pills {
    display: flex;
    gap: 10px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    padding: 6px;
    border-radius: var(--radius-full);
    border: 1px solid var(--glass-border);
}

.filter-btn {
    background: transparent;
    border: none;
    padding: 10px 20px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition-fast);
}

.filter-btn:hover, .filter-btn.active {
    background: white;
    color: var(--primary);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.journal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 30px;
}

.j-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(0,0,0,0.04);
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.j-card.hide {
    display: none;
}

.j-img {
    height: 200px;
    overflow: hidden;
    position: relative;
}

.j-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.j-card:hover .j-img img {
    transform: scale(1.08);
}

.j-tags-float {
    position: absolute;
    top: 16px;
    left: 16px;
    display: flex;
    gap: 8px;
    z-index: 2;
}

.j-tag {
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(10px);
}

.tag-s2 { background: rgba(249, 115, 22, 0.9); color: white; }
.tag-s3 { background: rgba(234, 179, 8, 0.9); color: white; }
.tag-s4 { background: rgba(34, 197, 94, 0.9); color: white; }
.tag-scopus { background: rgba(225, 29, 72, 0.9); color: white; }
.tag-doaj { background: rgba(13, 148, 136, 0.9); color: white; }

.j-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.j-body h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.j-body p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.j-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.j-action {
    color: var(--primary);
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
}

.j-action i {
    transition: transform 0.3s;
}

.j-action:hover i {
    transform: translateX(4px);
}

/* ==========================================================================
   Modal
   ========================================================================== */
.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(8px);
}

.modal-content {
    background: white;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    z-index: 10;
    transform: scale(0.95) translateY(20px);
    transition: var(--transition-smooth);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.modal.active .modal-content {
    transform: scale(1) translateY(0);
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    background: rgba(0,0,0,0.05);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition-fast);
    z-index: 10;
}

.modal-close:hover {
    background: rgba(0,0,0,0.1);
    transform: rotate(90deg);
}

.modal-body {
    padding: 40px;
}

.modal-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
}

.modal-cover {
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.modal-cover img {
    width: 100%;
    display: block;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-actions .btn {
    width: 100%;
}

.m-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.m-desc {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 30px;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}

.info-table th, .info-table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.info-table th {
    font-weight: 600;
    color: var(--text-primary);
    width: 150px;
}

.info-table td {
    color: var(--text-secondary);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    background: white;
    padding: 80px 0 40px;
    border-top: 1px solid rgba(0,0,0,0.05);
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

.f-about p {
    color: var(--text-secondary);
    margin: 20px 0;
    max-width: 400px;
    font-size: 0.95rem;
}

.socials {
    display: flex;
    gap: 12px;
}

.social-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-base);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: var(--transition-fast);
}

.social-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-3px);
}

.f-title {
    font-family: 'Outfit';
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.f-links {
    list-style: none;
}

.f-links li {
    margin-bottom: 12px;
}

.f-links a {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.f-links a:hover {
    color: var(--primary);
}

.contact-list {
    list-style: none;
}

.contact-list li {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.contact-list i {
    color: var(--primary);
    font-size: 1.2rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(0,0,0,0.05);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ==========================================================================
   Animations
   ========================================================================== */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeLeft {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4); }
    70% { box-shadow: 0 0 0 8px rgba(59, 130, 246, 0); }
    100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0); }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-desc {
        margin: 0 auto 40px;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .analytics-bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .chart-wide, .chart-square {
        grid-column: span 2;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .navbar-inner {
        padding: 12px 16px;
    }
    
    .nav-menu {
        position: fixed;
        top: 85px;
        left: 5%;
        width: 90%;
        background: var(--glass-bg);
        backdrop-filter: blur(20px);
        border: 1px solid var(--glass-border);
        border-radius: var(--radius-lg);
        padding: 24px;
        flex-direction: column;
        align-items: center;
        opacity: 0;
        visibility: hidden;
        transition: var(--transition-smooth);
        box-shadow: var(--glass-shadow);
        z-index: 99;
    }
    
    .nav-menu.active {
        opacity: 1;
        visibility: visible;
    }
    
    .nav-list {
        flex-direction: column;
        width: 100%;
        text-align: center;
    }
    
    .nav-actions {
        display: none;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .hero-bento {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .analytics-bento-grid {
        grid-template-columns: 1fr;
    }
    
    .chart-wide, .chart-square {
        grid-column: span 1;
    }
    
    .modal-grid {
        grid-template-columns: 1fr;
    }
}
