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

:root {
    --primary: #FFD700; /* PlayinExchange Gold */
    --primary-dark: #ccae00;
    --secondary: #A0A0A0;
    --accent: #E31B23; /* PlayinExchange Red */
    --success: #10b981;
    --danger: #ef4444;
    --bg-dark: #0F1012; /* PlayinExchange Dark Bg */
    --card-bg: #1A1C1E;
    --text-main: #FFFFFF;
    --text-muted: #A0A0A0;
    --border: rgba(255, 255, 255, 0.1);
    --shadow: 0 10px 30px rgba(0,0,0,0.5);
}

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

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

h1, h2, h3, .heading-font {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* MAIN NAVBAR */
.main-navbar {
    background: rgba(15, 16, 18, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 70px;
    display: flex;
    align-items: center;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo img {
    height: 40px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    transition: color 0.3s ease;
}

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

.btn-login {
    background: var(--accent);
    color: white !important;
    padding: 0.6rem 1.5rem;
    border-radius: 6px;
    font-weight: 700;
    transition: all 0.3s ease;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(227, 27, 35, 0.4);
    background: #c8161d;
}

.btn-secondary {
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 0.6rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: var(--primary);
    color: #000;
}

/* HERO SECTION */
.hero {
    padding: 6rem 0 4rem;
    text-align: center;
    background: linear-gradient(135deg, #0F1012 0%, #1A1C1E 100%);
    position: relative;
    border-bottom: 1px solid var(--border);
}

.hero::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 215, 0, 0.05) 0%, transparent 70%);
    z-index: 0;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--primary);
    position: relative;
    z-index: 1;
}

.hero p {
    color: var(--text-muted);
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

/* BLOG CARDS GRID */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2.5rem;
    padding: 4rem 0;
}

.blog-card {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: all 0.3s;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

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

.card-img {
    height: 200px;
    width: 100%;
    object-fit: cover;
    background: #000;
}

.card-content {
    padding: 1.5rem;
}

.card-tag {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.card-title {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-main);
}

.card-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

/* LOGIN PAGE */
.login-container {
    height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-dark);
}

.login-card {
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
    width: 100%;
    max-width: 400px;
    text-align: center;
    border: 1px solid var(--border);
}

.login-card h1 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--primary);
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    background: #25282c;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: white;
    font-size: 1rem;
}

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

/* DASHBOARD */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 260px;
    background: #111214;
    border-right: 1px solid var(--border);
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 100;
}

.main-content {
    margin-left: 260px;
    flex-grow: 1;
    padding: 2.5rem;
    background: var(--bg-dark);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    text-decoration: none;
    color: var(--text-muted);
    border-radius: 10px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.sidebar-nav a.active, .sidebar-nav a:hover {
    background: rgba(255, 215, 0, 0.1);
    color: var(--primary);
    border-color: rgba(255, 215, 0, 0.2);
}

.editor-container {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid var(--border);
}

.seo-card {
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.rich-editor-toolbar {
    background: #25282c;
    border: 1px solid var(--border);
    border-radius: 6px 6px 0 0;
    padding: 0.5rem;
    display: flex;
    gap: 0.5rem;
}

.toolbar-btn {
    background: #1A1C1E;
    color: white;
    border: 1px solid var(--border);
    padding: 0.4rem 0.8rem;
    cursor: pointer;
    border-radius: 4px;
}

.toolbar-btn:hover {
    background: var(--primary);
    color: #000;
}

#editor-content {
    min-height: 350px;
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-top: none;
    background: #1A1C1E;
    outline: none;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg);
}

.data-table th {
    text-align: left;
    padding: 1rem;
    background: #151719;
    border-bottom: 1px solid var(--border);
    color: var(--primary);
}

.data-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.status-badge {
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
}

.status-published { background: #10b981; color: white; }
.status-draft { background: #4b5563; color: white; }

.btn-icon {
    padding: 0.5rem;
    background: #25282c;
    border: 1px solid var(--border);
    color: var(--text-muted);
    cursor: pointer;
}

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

/* FOOTER */
footer {
    background: #090A0B;
    border-top: 1px solid var(--border);
    padding: 4rem 0;
    text-align: center;
}

@media (max-width: 768px) {
    .container {
        padding: 0 1.5rem;
    }
    .hero {
        padding: 4rem 0 3rem;
    }
    .hero h1 {
        font-size: 2.2rem;
    }
    .hero p {
        font-size: 1rem;
    }
    .nav-links {
        gap: 1rem;
    }
    .nav-links a:not(.btn-login) {
        display: none; /* Hide non-essential links in header on mobile */
    }
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 2rem 0;
    }
    .main-navbar {
        height: 60px;
    }
    .logo img {
        height: 30px;
    }
    .logo {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.8rem;
    }
    .card-content {
        padding: 1rem;
    }
}

/* DASHBOARD RESPONSIVENESS */
@media (max-width: 992px) {
    .sidebar {
        width: 80px;
        padding: 2rem 0.5rem;
        align-items: center;
    }
    .sidebar .logo span, 
    .sidebar-nav a span {
        display: none;
    }
    .main-content {
        margin-left: 80px;
        padding: 1.5rem;
    }
    .sidebar-nav a {
        justify-content: center;
        padding: 1rem;
    }
    .sidebar-nav a i {
        margin: 0;
        font-size: 1.2rem;
    }
}

/* Floating Support Button */
.floating-support {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #25D366;
    color: white;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    z-index: 9999;
    animation: pulse-whatsapp 2s infinite;
    text-align: center;
    line-height: 1;
}

.floating-support i {
    font-size: 1.8rem;
    margin-bottom: 2px;
}

.support-text {
    font-size: 0.6rem;
    font-weight: 800;
    text-transform: uppercase;
}

@keyframes pulse-whatsapp {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

@media (max-width: 768px) {
    .floating-support {
        bottom: 20px;
        right: 15px;
        width: 60px;
        height: 60px;
    }
    .floating-support i {
        font-size: 1.5rem;
    }
}

/* Floating Telegram Button */
.floating-telegram {
    position: fixed;
    bottom: 115px; /* Above WhatsApp */
    right: 30px;
    background: #0088cc;
    color: white;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    z-index: 9999;
    text-align: center;
    line-height: 1;
}

.floating-telegram i {
    font-size: 1.8rem;
    margin-bottom: 2px;
}

.telegram-text {
    font-size: 0.6rem;
    font-weight: 800;
    text-transform: uppercase;
}

@media (max-width: 768px) {
    .floating-telegram {
        bottom: 95px;
        right: 15px;
        width: 60px;
        height: 60px;
    }
    .floating-telegram i {
        font-size: 1.5rem;
    }
}
