@font-face {
    font-family: 'The Last Shuriken';
    src: url('../fonts/ClashDisplay-Bold.ttf') format('truetype');
    font-weight: bold;
}

@font-face {
    font-family: 'Mangaka';
    src: url('../fonts/ClashDisplay-Medium.ttf') format('truetype');
    font-weight: 500;
}

@font-face {
    font-family: 'Teacher';
    src: url('../fonts/ClashDisplay-Regular.ttf') format('truetype');
    font-weight: normal;
}

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

:root {
    --primary: #d71515;
    --bg-light: #f0ebe5;
    --bg-card: #fff;
    --text-dark: #010101;
    --text-gray: #868686;
    --border: #c3c3c3;
}

body {
    font-family: 'Teacher', sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
}

/* Navbar */
.navbar {
    position: fixed;
    width: 100%;
    padding: 20px 5%;
    background: rgba(240, 235, 229, 0.98);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    border-bottom: 1px solid rgba(195, 195, 195, 0.3);
    transition: all 0.3s;
}

.navbar.scrolled {
    padding: 15px 5%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.logo {
    font-size: 32px;
    font-weight: 900;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
}

.logo span {
    color: var(--primary);
}

.nav-menu {
    display: flex;
    gap: 35px;
    list-style: none;
    align-items: center;
}

.nav-menu a {
    color: var(--text-gray);
    text-decoration: none;
    font-weight: 500;
    text-transform: uppercase;
    font-size: 16px;
    transition: all 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
}

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

.action-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-gray);
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    border: 2px solid transparent;
}

.action-icon:hover {
    color: var(--primary);
    border-color: var(--primary);
}

.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary);
    color: white;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    border: 2px solid var(--bg-light);
}

.btn-primary {
    background: var(--primary);
    color: white;
    padding: 14px 32px;
    border-radius: 50px;
    text-transform: uppercase;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    border: none;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary:hover {
    background: #b01010;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(215, 21, 21, 0.3);
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-dropdown {
    position: absolute;
    top: 60px;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.15);
    min-width: 220px;
    padding: 20px 0;
    display: none;
    z-index: 1001;
}

.user-dropdown.active {
    display: block;
}

.user-info {
    padding: 0 20px 15px;
    border-bottom: 2px solid var(--bg-light);
    margin-bottom: 10px;
}

.user-dropdown a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-gray);
    text-decoration: none;
    transition: all 0.3s;
}

.user-dropdown a:hover {
    background: var(--bg-light);
    color: var(--primary);
}

/* Hero Section */
.hero {
    padding: 160px 5% 80px;
    background: linear-gradient(135deg, #f0ebe5 0%, #ece7e1 100%);
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 700px;
}

.hero-label {
    font-size: 18px;
    font-family: 'Mangaka', sans-serif;
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 20px;
    display: inline-block;
    position: relative;
    padding-left: 50px;
}

.hero-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 2px;
    background: var(--primary);
}

.hero h1 {
    font-size: 68px;
    font-weight: 900;
    font-family: 'The Last Shuriken', sans-serif;
    line-height: 1.1;
    margin-bottom: 25px;
    text-transform: uppercase;
    color: var(--text-dark);
}

.hero p {
    font-size: 18px;
    font-family: 'Teacher', sans-serif;
    color: var(--text-gray);
    margin-bottom: 35px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.btn-secondary {
    background: transparent;
    color: var(--text-dark);
    padding: 14px 32px;
    border-radius: 50px;
    text-transform: uppercase;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    border: 2px solid var(--text-dark);
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-secondary:hover {
    background: var(--text-dark);
    color: white;
}

/* Marquee */
.marquee {
    width: 100%;
    height: 70px;
    background: var(--primary);
    display: flex;
    align-items: center;
    overflow: hidden;
    position: relative;
}

.marquee-content {
    display: flex;
    animation: scroll 40s linear infinite;
    white-space: nowrap;
}

.marquee-item {
    display: flex;
    align-items: center;
    padding: 0 50px;
}

.marquee-item i {
    font-size: 26px;
    color: white;
    margin-right: 15px;
}

.marquee-text {
    font-size: 28px;
    font-weight: 800;
    font-family: 'The Last Shuriken', sans-serif;
    color: white;
    text-transform: uppercase;
    letter-spacing: 2px;
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Featured Section */
.section {
    padding: 90px 5%;
}

.section-header {
    margin-bottom: 50px;
    text-align: center;
}

.section-label {
    font-size: 18px;
    font-family: 'Mangaka', sans-serif;
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 15px;
    display: inline-block;
    position: relative;
    padding-left: 50px;
}

.section-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 2px;
    background: var(--primary);
}

.section-title {
    font-size: 56px;
    font-weight: 900;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--text-dark);
    margin-bottom: 20px;
    text-transform: uppercase;
}

.section-desc {
    font-size: 18px;
    color: var(--text-gray);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

/* Series Grid */
.series-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.series-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s;
    border: 3px solid transparent;
    cursor: pointer;
}

.series-card:hover {
    border-color: var(--primary);
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.series-image {
    width: 100%;
    height: 380px;
    object-fit: cover;
}

.series-info {
    padding: 25px;
}

.series-info h3 {
    font-size: 22px;
    font-weight: 700;
    font-family: 'Mangaka', sans-serif;
    color: var(--text-dark);
    margin-bottom: 8px;
    text-transform: uppercase;
}

.series-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-gray);
    font-size: 16px;
    font-family: 'Teacher', sans-serif;
}

.bookmark-icon {
    position: absolute;
    top: 25px;
    right: 25px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    cursor: pointer;
    transition: all 0.3s;
    border: 3px solid var(--bg-light);
    font-size: 18px;
}

.bookmark-icon:hover,
.bookmark-icon.bookmarked {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
}

/* Stats Section */
.stats {
    background: white;
    padding: 60px 5%;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    border-top: 2px solid var(--border);
    border-bottom: 2px solid var(--border);
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 52px;
    font-weight: 900;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--primary);
    margin-bottom: 10px;
}

.stat-label {
    font-size: 18px;
    font-family: 'Mangaka', sans-serif;
    color: var(--text-gray);
    text-transform: uppercase;
    font-weight: 600;
}

/* Categories */
.categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.category-card {
    background: white;
    padding: 40px 30px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s;
    border: 2px solid transparent;
    cursor: pointer;
}

.category-card:hover {
    border-color: var(--primary);
    transform: translateY(-5px);
}

.category-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: var(--primary);
    transition: all 0.3s;
}

.category-card:hover .category-icon {
    background: var(--primary);
    color: white;
}

.category-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
    text-transform: uppercase;
}

.category-count {
    font-size: 16px;
    color: var(--text-gray);
}

/* Auth Pages */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 20px 50px;
}

.auth-box {
    background: white;
    padding: 50px 40px;
    border-radius: 16px;
    max-width: 480px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.auth-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-header h2 {
    font-size: 42px;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--text-dark);
    margin-bottom: 10px;
    text-transform: uppercase;
}

.auth-header p {
    color: var(--text-gray);
    font-size: 16px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 16px;
}

.form-control {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 16px;
    font-family: 'Teacher', sans-serif;
    transition: all 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
}

.btn-block {
    width: 100%;
    margin-top: 10px;
}

.auth-footer {
    text-align: center;
    margin-top: 25px;
    font-size: 16px;
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin: 20px 5%;
    font-size: 16px;
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    z-index: 9999;
    animation: slideDown 0.3s;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 2px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 2px solid #f5c6cb;
}

/* Admin Dashboard */
.admin-container {
    padding: 120px 5% 50px;
}

.admin-header {
    margin-bottom: 40px;
}

.admin-header h1 {
    font-size: 48px;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--text-dark);
    margin-bottom: 10px;
    text-transform: uppercase;
}

.stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.stat-card {
    background: white;
    padding: 30px;
    border-radius: 12px;
    border: 2px solid var(--border);
    transition: all 0.3s;
}

.stat-card:hover {
    border-color: var(--primary);
    transform: translateY(-5px);
}

.stat-card h3 {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 15px;
    text-transform: uppercase;
    font-weight: 600;
}

.stat-card .number {
    font-size: 42px;
    font-family: 'The Last Shuriken', sans-serif;
    color: var(--primary);
}

.admin-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

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

.admin-table th,
.admin-table td {
    padding: 18px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.admin-table th {
    background: var(--bg-light);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 14px;
    color: var(--text-dark);
}

.admin-table tr:hover {
    background: var(--bg-light);
}

.action-btn {
    padding: 8px 16px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    transition: all 0.3s;
    margin-right: 8px;
}

.btn-edit {
    background: #ffc107;
    color: white;
}

.btn-delete {
    background: var(--primary);
    color: white;
}

.action-btn:hover {
    transform: translateY(-2px);
}

/* Footer */
.footer {
    background: #2a2a2a;
    padding: 80px 5% 30px;
    color: #a7a7a7;
}

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

.footer-logo {
    font-size: 42px;
    font-weight: 900;
    color: white;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.footer-logo span {
    color: var(--primary);
}

.footer-text {
    line-height: 1.8;
    margin-bottom: 25px;
    font-size: 16px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a7a7a7;
    transition: all 0.3s;
    text-decoration: none;
}

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

.footer-title {
    font-size: 22px;
    font-weight: 700;
    color: white;
    margin-bottom: 25px;
    text-transform: uppercase;
}

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

.footer-links a {
    color: #a7a7a7;
    text-decoration: none;
    display: block;
    margin-bottom: 15px;
    transition: all 0.3s;
    font-size: 16px;
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 2px solid #3d3d3d;
    font-size: 16px;
}

.copyright a {
    color: var(--primary);
    text-decoration: none;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.menu-toggle span {
    width: 35px;
    height: 3px;
    background: var(--primary);
    transition: all 0.3s;
}

/* Responsive */
@media (max-width: 991px) {
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: var(--bg-light);
        flex-direction: column;
        padding: 40px;
        transition: all 0.3s;
    }

    .nav-menu.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .hero h1 {
        font-size: 48px;
    }

    .section-title {
        font-size: 42px;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 575px) {
    .hero h1 {
        font-size: 36px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .section-title {
        font-size: 32px;
    }

    .stats {
        grid-template-columns: 1fr;
    }

    .series-grid {
        grid-template-columns: 1fr;
    }
    
    .auth-box {
        padding: 30px 25px;
    }
}
