/* ================================== */
/*          GENERAL & LAYOUT          */
/* ================================== */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #1a1a2e;
    color: #e0e0e0;
}

.page-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.main-content {
    flex-grow: 1;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 40px auto;
    background-color: #16213e;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    border: 1px solid #fca311;
}

h1, h2, h3 {
    color: #fca311;
    text-align: center;
    margin-bottom: 25px;
}

a {
    color: #fca311;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ================================== */
/*         NAVIGATION & FOOTER        */
/* ================================== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background-color: #16213e;
    border-bottom: 2px solid #fca311;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fca311;
}

.nav-logo:hover {
    text-decoration: none;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-links a {
    font-weight: bold;
    font-size: 1rem;
}

.nav-links .nav-cta {
    background-color: #fca311;
    color: #16213e !important;
    padding: 8px 15px;
    border-radius: 5px;
}

.nav-links .nav-cta:hover {
    background-color: #ffb742;
    text-decoration: none;
}

.footer {
    text-align: center;
    padding: 25px 0;
    background-color: #16213e;
    border-top: 1px solid #2c3e50;
    width: 100%;
    flex-shrink: 0;
}

.footer-links {
    margin-bottom: 15px;
}

.footer-links a {
    margin: 0 15px;
    color: #95a5a6;
    font-weight: bold;
    font-size: 0.9em;
}

.footer-links a:hover {
    color: #fca311;
    text-decoration: none;
}

.footer-links span {
    color: #4a4a4a;
}

.footer p {
    margin: 0;
    color: #7f8c8d;
    font-size: 0.9em;
}

/* ================================== */
/*           FORMS & BUTTONS          */
/* ================================== */
.form-container {
    max-width: 500px;
    margin: 0 auto;
}

form {
    display: flex;
    flex-direction: column;
}

form p {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;
}

label {
    margin-bottom: 5px;
    font-weight: bold;
    color: #c5c6c7;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea {
    background-color: #2c3e50;
    border: 1px solid #fca311;
    color: #ecf0f1;
    padding: 12px;
    border-radius: 5px;
    font-size: 16px;
    width: 100%;
    box-sizing: border-box;
}

input:focus, textarea:focus {
    outline: none;
    box-shadow: 0 0 5px #fca311;
}

.form-footer {
    text-align: center;
    margin-top: 20px;
}

.cta-button, button[type="submit"] {
    background-color: #fca311;
    color: #1a1a2e;
    border: none;
    padding: 12px;
    border-radius: 5px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 10px;
    text-align: center;
    display: inline-block;
    width: 100%;
    box-sizing: border-box;
}

.cta-button:hover, button[type="submit"]:hover {
    background-color: #ffb742;
    text-decoration: none;
    color: #16213e;
}

/* ================================== */
/*         DASHBOARD STYLES           */
/* ================================== */
.stat-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.stat-card {
    background-color: #1e2a38;
    border-radius: 8px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-card-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #16213e;
    background-color: #fca311;
    flex-shrink: 0;
}

.stat-card-info {
    display: flex;
    flex-direction: column;
}

.stat-card-title {
    color: #95a5a6;
    font-size: 0.9em;
    text-transform: uppercase;
}

.stat-card-value {
    color: #ffffff;
    font-size: 2.1em;
    font-weight: 700;
}

.actions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-bottom: 40px;
}

.action-card {
    background-color: #1e2a38;
    padding: 25px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
}

.action-card h3 {
    text-align: left;
    font-size: 1.4em;
}

.action-card p {
    color: #95a5a6;
    flex-grow: 1;
    margin-bottom: 20px;
}

.referral-code-box {
    display: flex;
}

.referral-code-box input {
    flex-grow: 1;
}

.copy-btn {
    background-color: #fca311;
    color: #1a1a2e;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    margin: 0;
    font-weight: bold;
}

.copy-btn:hover {
    background-color: #ffb742;
}

.action-card .cta-button {
    width: 100%;
    margin: 0;
}

.table-section {
    background-color: #1e2a38;
    padding: 30px;
    border-radius: 8px;
    margin-top: 40px;
}

.table-section h2 {
    text-align: left;
    margin-bottom: 20px;
}

.table-container {
    overflow-x: auto;
}

.dashboard-table {
    width: 100%;
    border-collapse: collapse;
}

.dashboard-table th, .dashboard-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #2c3e50;
}

.dashboard-table thead th {
    color: #95a5a6;
    font-size: 0.9em;
    text-transform: uppercase;
    font-weight: normal;
}

.dashboard-table tbody tr:last-child td {
    border-bottom: none;
}

.action-button-renew {
    background-color: #fca311;
    color: #1a1a2e;
    padding: 8px 12px;
    border-radius: 5px;
    font-weight: bold;
    display: inline-block;
}

.status-badge {
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
    color: white;
    display: inline-block;
    min-width: 70px;
    text-align: center;
}

.status-active { background-color: #27ae60; }
.status-expired { background-color: #c0392b; }
.status-pending { background-color: #f39c12; }

.no-data-message {
    text-align: center;
    padding: 40px;
}

.history-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-top: 40px;
}

@media (min-width: 992px) {
    .history-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.amount-positive { color: #27ae60; }
.amount-negative { color: #e74c3c; }

/* ================================== */
/*         OTHER PAGE STYLES          */
/* ================================== */
.legal-page h1, .legal-page h2 {
    text-align: left;
}

.legal-page h2 {
    margin-top: 30px;
    border-bottom: 2px solid #2c3e50;
    padding-bottom: 5px;
}

.legal-page p {
    line-height: 1.7;
    color: #bdc3c7;
}

.terms-field {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}
.terms-field input[type="checkbox"] {
    width: auto;
    margin: 0;
}
.terms-field label {
    margin: 0;
    font-weight: normal;
    font-size: 0.9em;
}
.terms-field a {
    text-decoration: underline;
}
.error-message {
    color: #e74c3c;
    font-size: 0.9em;
    display: block;
    width: 100%;
}

/* ================================== */
/*         RESPONSIVE STYLES          */
/* ================================== */
@media (max-width: 768px) {
    .actions-grid {
        grid-template-columns: 1fr;
    }
    .dashboard-table thead {
        display: none;
    }
    .dashboard-table, .dashboard-table tbody, .dashboard-table tr, .dashboard-table td {
        display: block;
        width: 100%;
    }
    .dashboard-table tr {
        margin-bottom: 15px;
        border: 1px solid #2c3e50;
        border-radius: 8px;
        padding: 10px;
    }
    .dashboard-table td {
        text-align: right;
        padding-left: 50%;
        position: relative;
        border-bottom: 1px solid #2c3e50;
    }
    .dashboard-table td:last-child {
        border-bottom: none;
    }
    .dashboard-table td::before {
        content: attr(data-label);
        position: absolute;
        left: 15px;
        width: calc(50% - 30px);
        padding-right: 10px;
        white-space: nowrap;
        text-align: left;
        font-weight: bold;
        color: #95a5a6;
    }
}

/* ================================== */
/*     HOME PAGE ENHANCEMENTS         */
/* ================================== */

/* BOTS SECTION - HOVER EFFECT */
.bots-section .bot-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bots-section .bot-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
}

/* ================================== */
/* ✅ STYLE NSHYA YO GUKOSORA LOGO ✅ */
/* ================================== */
.bot-logo {
    height: 80px; /* Gabanya uburebure bwa logo */
    width: auto; /* Reka ubugari bwiyize */
    margin-bottom: 15px; /* Umwanya munsi ya logo */
    object-fit: contain; /* Kugira ngo logo itiyongora nabi */
}


/* ENHANCED HERO SECTION */
.hero-section-enhanced {
    position: relative;
    padding: 80px 20px;
    background-image: url('../images/background-image.jpg');
    background-size: cover;
    background-position: center center;
    border-radius: 10px;
    overflow: hidden;
    color: #ffffff;
    margin-bottom: 40px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(22, 33, 62, 0.8);
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    color: #ffffff;
    font-size: 2.8rem;
    font-weight: 700;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.5);
}

.hero-content .lead {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* STYLE Y'IMIBARA IGENDA */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.stat-item {
    text-align: center;
    padding: 20px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(252, 163, 17, 0.3);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
}

.stat-title {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    margin: 5px 0 0 0;
}

/* Responsive styles for stats grid */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .hero-section-enhanced {
        padding: 60px 20px;
    }
    .hero-content h1 {
        font-size: 2.2rem;
    }
    .stat-number {
        font-size: 2rem;
    }
}
