:root {
    --primary: #c0392b;
    /* Dark Red */
    --primary-hover: #e74c3c;
    /* Lighter Red */
    --bg-dark: #0a0a0a;
    --bg-card: #141414;
    --text-main: #ffffff;
    --text-muted: #aaaaaa;
    --border-color: #333333;
    --success: #2ecc71;
    --danger: #e74c3c;
    --warning: #f1c40f;
    --font-main: 'Outfit', sans-serif;
}

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

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

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

/* --- Typography --- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    margin-bottom: 1rem;
}

/* --- Layout --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 40px;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: linear-gradient(45deg, var(--primary), #ff6b6b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: glow 3s ease-in-out infinite;
}

/* --- Header --- */
.main-header {
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    height: 80px;
    display: flex;
    align-items: center;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-main);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 40px;
    width: auto;
    margin-right: 10px;
    animation: spin 6s linear infinite;
}

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

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    color: var(--text-muted);
}

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

.btn-nav {
    border: 1px solid var(--primary);
    padding: 8px 20px;
    border-radius: 4px;
    color: var(--primary) !important;
    transition: all 0.3s ease;
}

.btn-nav:hover {
    background: var(--primary);
    color: #fff !important;
}

/* --- Hero --- */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #2e0e0e 0%, var(--bg-dark) 80%);
    text-align: center;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: url('https://www.transparenttextures.com/patterns/cubes.png');
    opacity: 0.05;
    animation: moveBackground 20s linear infinite;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    line-height: 1.1;
    animation: fadeInUp 1s ease-out;
}

.hero p {
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    animation: fadeInUp 1s ease-out 0.2s backwards;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
    animation: fadeInUp 1s ease-out 0.4s backwards;
}

.ip-box {
    background: rgba(255, 255, 255, 0.05);
    padding: 15px 30px;
    border-radius: 8px;
    border: 1px dashed var(--border-color);
    font-family: monospace;
    font-size: 1.2rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
}

.ip-box:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: scale(1.05);
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 0.9rem;
    border: 1px solid var(--primary);
}

.btn:hover {
    background: var(--primary-hover);
    border-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(192, 57, 43, 0.3);
}

/* --- Staff Grid & Animations --- */
.staff-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.staff-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeInUp 0.6s ease-out forwards;
}

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

.staff-card img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    margin-bottom: 15px;
    border: 2px solid var(--primary);
    transition: transform 0.5s;
    object-fit: contain;
}

.staff-card:hover img {
    transform: rotate(360deg) scale(1.1);
}

/* Staff 3D Canvas */
.staff-card canvas {
    cursor: grab;
    transition: transform 0.3s ease;
}

.staff-card canvas:active {
    cursor: grabbing;
}

/* --- Animations Keyframes --- */
@keyframes spin {
    0% {
        transform: perspective(1000px) rotateY(0deg);
    }

    100% {
        transform: perspective(1000px) rotateY(-360deg);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes moveBackground {
    from {
        transform: translate(0, 0);
    }

    to {
        transform: translate(-50px, -50px);
    }
}

@keyframes glow {
    from {
        text-shadow: 0 0 10px rgba(192, 57, 43, 0.2);
    }

    to {
        text-shadow: 0 0 20px rgba(192, 57, 43, 0.6);
    }
}

/* --- Forms --- */
.form-container {
    max-width: 600px;
    margin: 0 auto;
    background: var(--bg-card);
    padding: 40px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    animation: fadeInUp 0.8s ease-out;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 12px;
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-main);
    font-family: var(--font-main);
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    transform: scale(1.02);
    box-shadow: 0 0 15px rgba(192, 57, 43, 0.3);
}

/* --- Admin Tables --- */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: var(--bg-card);
    border-radius: 8px;
    overflow: hidden;
    animation: fadeInUp 0.6s ease-out;
}

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

.data-table th {
    background: #000;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.85rem;
}

.data-table tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* --- Status Badges --- */
.status-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 700;
}

.status-pending {
    background: rgba(241, 196, 15, 0.2);
    color: #f1c40f;
}

.status-accepted {
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
}

.status-rejected {
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
}

/* --- Admin Header --- */
.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

/* --- Footer --- */
.main-footer {
    border-top: 1px solid var(--border-color);
    padding: 40px 0;
    margin-top: 80px;
    text-align: center;
    color: var(--text-muted);
}

.socials {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.socials a {
    font-size: 1.5rem;
    color: var(--text-muted);
    transition: transform 0.3s;
}

.socials a:hover {
    color: var(--primary);
    transform: scale(1.2) rotate(10deg);
}

/* --- Advanced Animations & Interactions --- */

/* Modal Animation */
.modal-content,
#add-modal>div {
    animation: scaleIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes scaleIn {
    from {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0;
    }

    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

/* Nav Link Hover Effect */
.nav-links a {
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Pulse Animation for important badges/buttons */
.status-badge.status-pending {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(241, 196, 15, 0.4);
    }

    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(241, 196, 15, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(241, 196, 15, 0);
    }
}

/* Main Content Entrance */
main {
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Floating IP Box */
.ip-box {
    animation: fadeInUp 1s ease-out 0.6s backwards, float 3s ease-in-out 2s infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* Button Shine Effect */
.btn {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
    z-index: -1;
}

.btn:hover::after {
    left: 100%;
}

/* Table Row Interaction */
.data-table tr {
    transition: transform 0.2s, background-color 0.2s;
}

.data-table tr:hover {
    transform: scale(1.01);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Staggered Grid Animation (up to 10 items) */
.staff-card:nth-child(1) {
    animation-delay: 0.1s;
}

.staff-card:nth-child(2) {
    animation-delay: 0.2s;
}

.staff-card:nth-child(3) {
    animation-delay: 0.3s;
}

.staff-card:nth-child(4) {
    animation-delay: 0.4s;
}

.staff-card:nth-child(5) {
    animation-delay: 0.5s;
}

.staff-card:nth-child(6) {
    animation-delay: 0.6s;
}

.staff-card:nth-child(7) {
    animation-delay: 0.7s;
}

.staff-card:nth-child(8) {
    animation-delay: 0.8s;
}

.staff-card:nth-child(9) {
    animation-delay: 0.9s;
}

.staff-card:nth-child(10) {
    animation-delay: 1s;
}

/* --- Forum Specifico --- */
.forum-post-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
}

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

.forum-author-info {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.forum-author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    object-fit: cover;
}

.forum-author-name {
    color: var(--text-main);
}

.forum-author-name strong {
    display: block;
}

.forum-author-date {
    color: var(--text-muted);
    font-size: 0.85rem;
    display: block;
}

.forum-post-title {
    font-size: 1.3rem;
    margin: 10px 0;
    color: var(--text-main);
}

.forum-post-preview {
    color: var(--text-muted);
    margin: 10px 0;
    line-height: 1.6;
}

.forum-post-meta {
    color: var(--primary);
    font-size: 0.9rem;
}

.forum-comments-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
}

.forum-comment {
    background: rgba(0, 0, 0, 0.3);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 3px solid var(--primary);
    transition: all 0.3s ease;
}

.forum-comment:hover {
    background: rgba(0, 0, 0, 0.5);
    transform: translateX(5px);
}

.forum-comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.forum-comment-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.forum-comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid var(--primary);
    object-fit: cover;
}

.forum-comment-name {
    font-weight: 600;
    color: var(--text-main);
}

.forum-comment-date {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.forum-comment-content {
    color: var(--text-main);
    line-height: 1.6;
    margin: 10px 0;
    white-space: pre-wrap;
    word-break: break-word;
}

.forum-no-posts {
    text-align: center;
    color: var(--text-muted);
    padding: 40px;
    background: var(--bg-card);
    border: 1px dashed var(--border-color);
    border-radius: 8px;
}

.forum-no-comments {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
}

.alert {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    animation: fadeInUp 0.4s ease-out;
}

.alert-success {
    background: rgba(46, 204, 113, 0.1);
    border: 1px solid rgba(46, 204, 113, 0.3);
    color: #2ecc71;
}

.alert-danger {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: #e74c3c;
}

.role-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Forum Guide Section */
#guide-section .staff-card {
    text-align: left;
}

#guide-section .staff-card h3 {
    color: var(--primary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

#guide-section .staff-card p {
    font-size: 0.95rem;
    line-height: 1.6;
}

#guide-section .btn {
    width: 100%;
    text-align: center;
    justify-content: center;
}

/* Forum Post Card Animation */
.forum-post-card {
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0;
}

/* Action Buttons Responsive */
#action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

#action-buttons .btn {
    white-space: nowrap;
}

@media (max-width: 768px) {
    #action-buttons {
        flex-direction: column;
    }
    
    #action-buttons .btn {
        width: 100%;
    }
    
    .admin-header {
        flex-direction: column;
    }
    
    .admin-header h2 {
        width: 100%;
    }
}