/* ========================================
   Global Phucios-like Theme Override
   Scope: public/frontend pages only
   Goal: one consistent visual language without touching business logic
   ======================================== */

:root {
    --ph-bg: #0f1015;
    --ph-bg-deep: #0b0c10;
    --ph-card: #1c1e26;
    --ph-card-2: #161b29;
    --ph-border: #34373e;
    --ph-border-soft: #23262f;
    --ph-cyan: #4ee2ff;
    --ph-cyan-soft: rgba(78, 226, 255, 0.12);
    --ph-green: #2ecc71;
    --ph-lime: #ccfe1e;
    --ph-yellow: #ffb300;
    --ph-purple: #6366f1;
    --ph-violet: #a855f7;
    --ph-text: #ffffff;
    --ph-muted: #949ba4;
    --ph-muted-2: #666f7b;
    --neon-cyan: var(--ph-cyan) !important;
    --neon-purple: var(--ph-violet) !important;
    --neon-pink: var(--ph-purple) !important;
    --dark-bg: var(--ph-bg) !important;
    --dark-card: var(--ph-card) !important;
    --dark-surface: var(--ph-card-2) !important;
    --dark-border: var(--ph-border) !important;
    --gradient-main: linear-gradient(90deg, var(--ph-purple), var(--ph-violet)) !important;
    --gradient-button: linear-gradient(90deg, var(--ph-purple), var(--ph-violet)) !important;
}

html, body {
    background: var(--ph-bg) !important;
    color: var(--ph-text) !important;
    font-family: 'Inter', 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
}
body::before,
.particles-bg,
.bg-grid::before,
.bg-grid::after {
    display: none !important;
}

main,
.civ-main {
    background: var(--ph-bg) !important;
}

/* Generic cards / panels */
.bg-dark-card,
.bg-dark-surface,
.auth-card,
.profile-card,
.filter-sidebar,
.package-card > div,
.cat-block-header,
.cat-block,
.mk-step-card,
.mk-feature,
.ph-flash,
.ph-desc-box,
.premium-card-glass,
.hax-editor,
.discord-announcement-bar,
.prm-modal-card,
#deposit-modal .bg-dark-card,
#buy-modal .bg-dark-card,
[id$="modal"] .bg-dark-card {
    background: var(--ph-card) !important;
    border-color: var(--ph-border-soft) !important;
    color: var(--ph-text) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, .32) !important;
}

.border-dark-border,
.divide-dark-border > :not([hidden]) ~ :not([hidden]) {
    border-color: var(--ph-border-soft) !important;
}

.text-white,
.font-gaming,
.font-alt,
h1, h2, h3, h4, h5, h6 {
    color: var(--ph-text) !important;
}
.text-gray-400,
.text-gray-500,
.text-gray-600,
.game-sub-text,
.ph-desc-box .body,
.content-text-custom,
.footer-brand p,
.footer-col ul li a,
.small-note,
.footer-note-prm {
    color: var(--ph-muted) !important;
}
.text-neon-cyan,
.game-name-title,
.mk-product-name,
.mk-price-value,
.cat-block-title,
.ph-section-title h3 span,
.game-title-main span,
.prm-welcome-text span,
.ph-other-title span {
    color: var(--ph-cyan) !important;
}
.text-gradient {
    background: none !important;
    -webkit-text-fill-color: initial !important;
    color: var(--ph-cyan) !important;
}

/* Header / menu */
.civ-navbar {
    background: rgba(11, 11, 20, .96) !important;
    border-bottom: 1px solid rgba(255,255,255,.08) !important;
    backdrop-filter: blur(15px) !important;
}
.civ-sidebar {
    background: #0f0f1b !important;
}
.menu-list li a {
    background: rgba(255,255,255,.03) !important;
    border: 1px solid rgba(255,255,255,.08) !important;
    color: #e2e8f0 !important;
    border-radius: 15px !important;
}
.menu-list li a:hover,
.menu-list li a.active {
    background: rgba(99, 102, 241, .1) !important;
    border-color: var(--ph-cyan) !important;
    color: var(--ph-text) !important;
}
.menu-list li a i {
    color: #818cf8 !important;
}

/* Product cards */
.mk-product-card,
.card-dashed-custom {
    background: var(--ph-card) !important;
    border: 2px dashed var(--ph-border) !important;
    border-radius: 20px !important;
    overflow: hidden !important;
    box-shadow: none !important;
}
.mk-product-card:hover,
.card-dashed-custom:hover {
    border-color: var(--ph-cyan) !important;
    transform: translateY(-5px) !important;
    box-shadow: 0 10px 30px rgba(78, 226, 255, .1) !important;
}
.mk-product-img {
    padding: 0 !important;
    aspect-ratio: 16/9 !important;
    background: #000 !important;
}
.mk-product-img img,
.img-game-standard {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 0 !important;
}
.mk-product-info,
.card-content-custom {
    padding: 18px !important;
}
.mk-product-name,
.game-name-title {
    font-size: 15px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: .3px !important;
}
.mk-btn-order,
.btn-buy-custom {
    margin-top: auto !important;
    border: 1px solid var(--ph-border) !important;
    background: transparent !important;
    color: var(--ph-text) !important;
    padding: 12px !important;
    border-radius: 12px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 10px !important;
}
.mk-product-card:hover .mk-btn-order,
.card-dashed-custom:hover .btn-buy-custom,
.btn-buy-custom:hover {
    background: #fff !important;
    color: #000 !important;
    border-color: #fff !important;
}
.mk-badge-status,
.badge-status {
    background: rgba(46, 204, 113, .95) !important;
    color: #fff !important;
    border: none !important;
}

/* Buttons */
.btn-primary,
.btn-login,
#btn-send-auth {
    background: linear-gradient(90deg, var(--ph-purple), var(--ph-violet)) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 6px 18px rgba(99,102,241,.28) !important;
}
.btn-primary:hover,
.btn-login:hover,
#btn-send-auth:hover {
    filter: brightness(1.08) !important;
    transform: translateY(-2px) !important;
}
.btn-secondary {
    background: var(--ph-card-2) !important;
    border: 1px solid var(--ph-border) !important;
    color: var(--ph-muted) !important;
}

/* Inputs */
input,
select,
textarea,
.auth-input,
.input-nice,
#modal-qty,
#modal-coupon,
#custom-amount {
    background: var(--ph-card-2) !important;
    border-color: var(--ph-border) !important;
    color: #fff !important;
    border-radius: 10px !important;
}
input::placeholder,
textarea::placeholder {
    color: #64748b !important;
}
input:focus,
select:focus,
textarea:focus,
.auth-input:focus,
.input-nice:focus {
    border-color: var(--ph-cyan) !important;
    box-shadow: 0 0 0 3px rgba(78,226,255,.08) !important;
    outline: none !important;
}

/* Guide / product detail */
.game-title-main,
.ph-prod-title h1,
.ph-section-title h3 {
    color: #fff !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
}
.title-line,
.ph-section-title .line {
    background: var(--ph-cyan) !important;
}
.btn-premium-action,
.btn-buy-hack,
.btn-custom-hd {
    border-radius: 12px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
}
.btn-buy-now {
    background: #fff !important;
    color: #000 !important;
}
.btn-buy-now:hover {
    background: var(--ph-cyan) !important;
    color: #000 !important;
}
.btn-download {
    background: rgba(78,226,255,.1) !important;
    color: var(--ph-cyan) !important;
    border: 1px solid rgba(78,226,255,.3) !important;
}
.btn-download:hover {
    background: var(--ph-cyan) !important;
    color: #000 !important;
}
.btn-support {
    background: var(--ph-card) !important;
    color: var(--ph-muted) !important;
    border: 1px solid var(--ph-border) !important;
}
.btn-custom-hd,
.btn-guide-yellow {
    background: var(--ph-yellow) !important;
    color: #000 !important;
}
.hax-editor-status,
.guide-key-badge {
    background: rgba(46,204,113,.95) !important;
    color: #fff !important;
}

/* Announcement / modal */
.announcement-tag {
    background: var(--ph-cyan) !important;
    color: #000 !important;
}
.prm-line-glow {
    background: linear-gradient(90deg, transparent, var(--ph-cyan), transparent) !important;
}
.prm-btn-confirm {
    background: #fff !important;
    color: #000 !important;
}
.prm-btn-confirm:hover {
    background: var(--ph-cyan) !important;
}

/* Auth pages */
.login-box,
.auth-card {
    background: rgba(20,21,26,.9) !important;
    border: 1px solid rgba(255,255,255,.08) !important;
    border-radius: 24px !important;
}
.login-title h1 span {
    background: linear-gradient(to right, var(--ph-cyan), var(--ph-violet)) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}

/* Footer */
#civ-footer-custom {
    background: #0f1012 !important;
}
.newsletter-card {
    background: #1a1b1e !important;
    border-color: rgba(78,226,255,.12) !important;
}
.footer-bottom {
    background: #090a0b !important;
}
.footer-bottom .hl,
.footer-bottom span.hl {
    color: var(--ph-cyan) !important;
}

/* Home grouped categories */
.ph-category-stack {
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin-bottom: 18px;
}
.ph-category-block {
    background: var(--ph-card) !important;
    border: 1px solid var(--ph-border-soft) !important;
    border-radius: 20px;
    padding: 16px;
}
.ph-category-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.ph-category-head h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    color: #fff !important;
    text-transform: uppercase;
}
.ph-category-head p {
    margin: 4px 0 0;
    color: var(--ph-muted) !important;
    font-size: 12px;
}
.ph-category-head a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--ph-cyan) !important;
    font-weight: 700;
    text-decoration: none;
    font-size: 13px;
    white-space: nowrap;
}
.ph-category-head a:hover { color: #fff !important; }

.ph-category-grid {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 48px;
}
@media (min-width: 640px) { .ph-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .ph-category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ph-game-category-card {
    display: flex;
    flex-direction: column;
    background: var(--ph-card) !important;
    border: 2px dashed var(--ph-border) !important;
    border-radius: 25px;
    overflow: hidden;
    color: inherit;
    text-decoration: none !important;
    transition: .3s;
}
.ph-game-category-card:hover {
    border-color: var(--ph-cyan) !important;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(78,226,255,.1) !important;
}
.ph-game-category-img {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
    overflow: hidden;
}
.ph-game-category-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .45s ease;
}
.ph-game-category-card:hover .ph-game-category-img img { transform: scale(1.06); }
.ph-game-category-placeholder {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 42px;
    background: linear-gradient(135deg, #1c1e26, #0f1015);
}
.ph-game-category-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(46,204,113,.95);
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 7px;
}
.ph-game-category-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.ph-game-category-body h5 {
    margin: 0 0 8px;
    color: var(--ph-cyan) !important;
    font-size: 17px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .4px;
}
.ph-game-category-body p {
    margin: 0 0 18px;
    color: var(--ph-muted) !important;
    font-size: 13px;
    line-height: 1.45;
}
.ph-game-category-body span {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 12px;
    border-radius: 12px;
    border: 1px solid var(--ph-border);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    transition: .25s;
}
.ph-game-category-card:hover .ph-game-category-body span {
    background: #fff;
    color: #000;
    border-color: #fff;
}

/* Kill old neon leftovers */
[style*="#00f0ff"] { border-color: var(--ph-cyan) !important; color: var(--ph-cyan) !important; }
.shadow-neon,
.shadow-neon-cyan,
.shadow-neon-purple {
    box-shadow: none !important;
}

/* Keep admin isolated */
body.admin-page * {
    /* no-op placeholder: admin has its own layout */
}
