:root {
    --bg-canvas: #FAFBFC;
    --bg-surface: #FFFFFF;
    --text-primary: #1A1A1A;
    --text-secondary: #6B7280;
    --accent-start: #0066FF;
    --accent-end: #6366F1;
    --accent-glow: rgba(99, 102, 241, 0.3);

    --shadow-premium:
        0 1px 3px rgba(0, 0, 0, 0.02),
        0 4px 8px rgba(0, 0, 0, 0.03),
        0 12px 24px rgba(0, 0, 0, 0.04),
        0 24px 48px rgba(0, 0, 0, 0.05);

    --shadow-hover:
        0 4px 6px rgba(0, 0, 0, 0.03),
        0 12px 16px rgba(0, 0, 0, 0.04),
        0 24px 32px rgba(0, 0, 0, 0.06),
        0 48px 64px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(99, 102, 241, 0.1),
        0 0 32px rgba(99, 102, 241, 0.15);

    --radius-lg: 20px;
    --radius-md: 12px;

    --font-heading: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: linear-gradient(180deg, #FAFBFC 0%, #F4F6F8 100%);
    font-family: var(--font-heading);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
}

/* --- Premium Header --- */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 2rem;
}

.brand {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent-start), var(--accent-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.03em;
    text-decoration: none;
    transition: transform 0.3s;
}

.brand:hover {
    transform: scale(1.02);
}

.btn-ghost {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-md);
    transition: all 0.2s;
    border: 1px solid transparent;
}

.btn-ghost:hover {
    background: rgba(99, 102, 241, 0.08);
    color: var(--accent-end);
    border-color: rgba(99, 102, 241, 0.2);
}

/* --- Hero Section --- */
.hero {
    text-align: center;
    padding: 4rem 0 3rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.5) 100%);
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #1A1A1A 0%, #4B5563 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-weight: 500;
}

.search-bar {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 1rem 1.5rem 1rem 3.5rem;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    font-size: 1rem;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.search-bar input:focus {
    outline: none;
    border-color: var(--accent-end);
    box-shadow: 0 0 0 4px var(--accent-glow), 0 8px 24px rgba(0, 0, 0, 0.08);
}

.search-bar::before {
    content: "🔍";
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    opacity: 0.5;
}

/* --- Bento Grid Premium --- */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    grid-auto-rows: 280px;
    grid-auto-flow: dense;
    gap: 2rem;
    padding: 2rem 0 4rem;
}

.card {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-premium);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(255, 255, 255, 0.8);
    height: 100%;
    padding: 0;
    cursor: pointer;
    animation: cardFadeIn 0.6s ease-out backwards;
}

@keyframes cardFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger animation for cards */
.card:nth-child(1) {
    animation-delay: 0.05s;
}

.card:nth-child(2) {
    animation-delay: 0.1s;
}

.card:nth-child(3) {
    animation-delay: 0.15s;
}

.card:nth-child(4) {
    animation-delay: 0.2s;
}

.card:nth-child(5) {
    animation-delay: 0.25s;
}

.card:nth-child(6) {
    animation-delay: 0.3s;
}

.card:nth-child(7) {
    animation-delay: 0.35s;
}

.card:nth-child(8) {
    animation-delay: 0.4s;
}

.card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: var(--shadow-hover);
    border-color: rgba(99, 102, 241, 0.3);
}

.card.w-2 {
    grid-column: span 2;
}

.card.h-2 {
    grid-row: span 2;
}

@media (max-width: 768px) {
    .card.w-2 {
        grid-column: span 1;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }
}

/* Card Content */
.card-preview {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
    overflow: hidden;
}

.card-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover .card-preview img {
    transform: scale(1.08);
}

.card-preview .icon-holder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #F8FAFC 0%, #EEF2F7 100%);
    color: var(--accent-end);
}

/* Glassmorphism Overlay */
.card-meta {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.5);
    border-bottom-left-radius: var(--radius-lg);
    border-bottom-right-radius: var(--radius-lg);
    transition: all 0.3s;
}

.card:hover .card-meta {
    background: rgba(255, 255, 255, 0.95);
    padding: 1.75rem 1.5rem;
}

.card-meta h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.card-meta p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 1;
    line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0;
    font-weight: 500;
}

.download-pill {
    display: none;
}

/* --- Premium Footer --- */
footer {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.9) 100%);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    margin-top: 4rem;
    padding: 3rem 0 2rem;
}

footer a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
    position: relative;
}

footer a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-start), var(--accent-end));
    transition: width 0.3s;
}

footer a:hover {
    color: var(--accent-end) !important;
}

footer a:hover::after {
    width: 100%;
}

/* --- Admin Styles --- */
.login-card,
.form-group,
.input-field,
.btn-primary,
.upload-zone,
.admin-file-list,
.file-row,
.file-info,
.btn-icon {
    /* Keep existing admin styles */
}/ *   - - -   A d m i n   U I   - - -   * /  
 . l o g i n - c a r d   {  
         m a x - w i d t h :   4 0 0 p x ;  
         m a r g i n :   4 r e m   a u t o ;  
         b a c k g r o u n d :   v a r ( - - b g - s u r f a c e ) ;  
         p a d d i n g :   2 . 5 r e m ;  
         b o r d e r - r a d i u s :   v a r ( - - r a d i u s - l g ) ;  
         b o x - s h a d o w :   v a r ( - - s h a d o w - s o f t ) ;  
         t e x t - a l i g n :   c e n t e r ;  
 }  
  
 . f o r m - g r o u p   {  
         m a r g i n - b o t t o m :   1 . 5 r e m ;  
         t e x t - a l i g n :   l e f t ;  
 }  
  
 . f o r m - g r o u p   l a b e l   {  
         d i s p l a y :   b l o c k ;  
         m a r g i n - b o t t o m :   0 . 5 r e m ;  
         f o n t - s i z e :   0 . 9 r e m ;  
         c o l o r :   v a r ( - - t e x t - s e c o n d a r y ) ;  
         f o n t - w e i g h t :   5 0 0 ;  
 }  
  
 . i n p u t - f i e l d   {  
         w i d t h :   1 0 0 % ;  
         p a d d i n g :   0 . 7 5 r e m   1 r e m ;  
         b o r d e r :   1 p x   s o l i d   # E 2 E 8 F 0 ;  
         b o r d e r - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
         b a c k g r o u n d :   # F A F A F A ;  
         f o n t - s i z e :   1 r e m ;  
         t r a n s i t i o n :   a l l   0 . 2 s ;  
 }  
  
 . i n p u t - f i e l d : f o c u s   {  
         o u t l i n e :   n o n e ;  
         b o r d e r - c o l o r :   v a r ( - - a c c e n t - c o l o r ) ;  
         b o x - s h a d o w :   0   0   0   3 p x   v a r ( - - a c c e n t - g l o w ) ;  
         b a c k g r o u n d :   # F F F ;  
 }  
  
 . b t n - p r i m a r y   {  
         d i s p l a y :   i n l i n e - b l o c k ;  
         b a c k g r o u n d :   v a r ( - - a c c e n t - c o l o r ) ;  
         c o l o r :   w h i t e ;  
         p a d d i n g :   0 . 7 5 r e m   1 . 5 r e m ;  
         b o r d e r - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
         b o r d e r :   n o n e ;  
         f o n t - s i z e :   1 r e m ;  
         f o n t - w e i g h t :   6 0 0 ;  
         c u r s o r :   p o i n t e r ;  
         t r a n s i t i o n :   a l l   0 . 2 s ;  
         w i d t h :   1 0 0 % ;  
         t e x t - a l i g n :   c e n t e r ;  
 }  
  
 . b t n - p r i m a r y : h o v e r   {  
         f i l t e r :   b r i g h t n e s s ( 1 . 1 ) ;  
         b o x - s h a d o w :   0   4 p x   1 2 p x   v a r ( - - a c c e n t - g l o w ) ;  
 }  
  
 / *   U p l o a d   Z o n e   * /  
 . u p l o a d - z o n e   {  
         b o r d e r :   2 p x   d a s h e d   # C B D 5 E 0 ;  
         b o r d e r - r a d i u s :   v a r ( - - r a d i u s - l g ) ;  
         p a d d i n g :   4 r e m   2 r e m ;  
         t e x t - a l i g n :   c e n t e r ;  
         c u r s o r :   p o i n t e r ;  
         t r a n s i t i o n :   a l l   0 . 2 s ;  
         b a c k g r o u n d :   # F A F A F A ;  
         c o l o r :   v a r ( - - t e x t - s e c o n d a r y ) ;  
         m a r g i n - b o t t o m :   2 r e m ;  
 }  
  
 . u p l o a d - z o n e : h o v e r ,  
 . u p l o a d - z o n e . d r a g o v e r   {  
         b o r d e r - c o l o r :   v a r ( - - a c c e n t - c o l o r ) ;  
         b a c k g r o u n d :   r g b a ( 1 5 ,   8 2 ,   1 8 6 ,   0 . 0 2 ) ;  
         c o l o r :   v a r ( - - a c c e n t - c o l o r ) ;  
 }  
  
 / *   A d m i n   L i s t   * /  
 . a d m i n - f i l e - l i s t   {  
         m a r g i n - t o p :   3 r e m ;  
 }  
  
 . f i l e - r o w   {  
         d i s p l a y :   f l e x ;  
         a l i g n - i t e m s :   c e n t e r ;  
         p a d d i n g :   1 r e m ;  
         b a c k g r o u n d :   v a r ( - - b g - s u r f a c e ) ;  
         b o r d e r - b o t t o m :   1 p x   s o l i d   # E 2 E 8 F 0 ;  
 }  
  
 . f i l e - r o w : f i r s t - c h i l d   {  
         b o r d e r - t o p - l e f t - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
         b o r d e r - t o p - r i g h t - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
 }  
  
 . f i l e - r o w : l a s t - c h i l d   {  
         b o r d e r - b o t t o m :   n o n e ;  
         b o r d e r - b o t t o m - l e f t - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
         b o r d e r - b o t t o m - r i g h t - r a d i u s :   v a r ( - - r a d i u s - m d ) ;  
 }  
  
 . f i l e - i n f o   {  
         f l e x - g r o w :   1 ;  
         p a d d i n g :   0   1 r e m ;  
 }  
  
 . b t n - i c o n   {  
         b a c k g r o u n d :   n o n e ;  
         b o r d e r :   n o n e ;  
         c u r s o r :   p o i n t e r ;  
         c o l o r :   v a r ( - - t e x t - s e c o n d a r y ) ;  
         p a d d i n g :   0 . 5 r e m ;  
         b o r d e r - r a d i u s :   4 p x ;  
 }  
  
 . b t n - i c o n : h o v e r   {  
         b a c k g r o u n d :   # f 0 f 0 f 0 ;  
         c o l o r :   v a r ( - - d a n g e r - c o l o r ) ;  
 }  
 