/* =========================================================
   RAHISS DIGITAL PRODUCTS
   GLOBAL APPLICATION CSS
   Responsive Desktop / Tablet / Mobile
   ========================================================= */

:root{
    --primary:#0f5fc4;
    --primary2:#11b8c8;
    --dark:#102a43;
    --text:#1f2937;
    --muted:#667085;
    --bg:#f7f9fc;
    --white:#fff;
    --line:#e5e7eb;
    --success:#15803d;
    --danger:#b42318;
    --warning:#b54708;

    --radius-sm:8px;
    --radius-md:12px;
    --radius-lg:16px;

    --shadow-sm:0 1px 3px rgba(16,42,67,.05);
    --shadow-md:0 6px 20px rgba(16,42,67,.07);

    --container:1180px;
    --mobile-padding:15px;
}

/* =========================================================
   RESET / BASE
   ========================================================= */

*,
*::before,
*::after{
    box-sizing:border-box;
}

html{
    scroll-behavior:smooth;
    -webkit-text-size-adjust:100%;
}

body{
    margin:0;
    background:var(--bg);
    color:var(--text);
    font:15px/1.6 Arial,Helvetica,sans-serif;
    min-width:0;
    overflow-x:hidden;
}

body,
button,
input,
select,
textarea{
    font-family:Arial,Helvetica,sans-serif;
}

img,
picture,
video,
svg,
canvas{
    max-width:100%;
}

img{
    height:auto;
    display:block;
}

a{
    text-decoration:none;
    color:inherit;
}

button,
input,
select,
textarea{
    max-width:100%;
}

button{
    font:inherit;
}

h1,
h2,
h3,
h4,
h5,
h6,
p{
    overflow-wrap:anywhere;
}

main{
    min-height:50vh;
}

/* =========================================================
   CONTAINER
   ========================================================= */

.container{
    width:min(var(--container),calc(100% - 30px));
    margin-left:auto;
    margin-right:auto;
}

.container-fluid{
    width:100%;
    padding-left:15px;
    padding-right:15px;
}

/* =========================================================
   HEADER / NAVIGATION
   ========================================================= */

.header{
    background:#fff;
    border-bottom:1px solid var(--line);
    position:sticky;
    top:0;
    z-index:50;
}

.nav{
    min-height:74px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:22px;
    min-width:0;
}

.brand{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:190px;
    flex:0 0 auto;
}

.brand img{
    width:52px;
    height:52px;
    object-fit:contain;
    flex:0 0 auto;
}

.brand-text{
    font-weight:800;
    color:#103d83;
    line-height:1.1;
    overflow-wrap:anywhere;
}

.brand-text small{
    display:block;
    font-size:10px;
    color:#555;
    margin-top:3px;
    font-weight:600;
}

.navlinks{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:17px;
    flex-wrap:wrap;
    margin-left:auto;
    min-width:0;
}

.navlinks a{
    color:#344054;
    font-weight:600;
}

.navlinks a:hover{
    color:var(--primary);
}

.navlinks .btn{
    color:#fff;
}

.contact-mini{
    font-size:12px;
    color:var(--muted);
    white-space:nowrap;
}

/* =========================================================
   HERO
   ========================================================= */

.hero{
    background:#fff;
    padding:72px 0 64px;
    border-bottom:1px solid var(--line);
}

.hero-grid{
    display:grid;
    grid-template-columns:minmax(0,1.4fr) minmax(280px,.8fr);
    gap:35px;
    align-items:center;
}

.eyebrow{
    color:var(--primary);
    font-weight:800;
    text-transform:uppercase;
    letter-spacing:.6px;
    font-size:12px;
}

.hero h1{
    font-size:44px;
    line-height:1.12;
    color:var(--dark);
    margin:8px 0 15px;
}

.hero p{
    max-width:730px;
    color:var(--muted);
    font-size:17px;
}

.actions,
.hero-actions{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin-top:24px;
}

.hero-logo,
.hero-card{
    background:#fff;
    border:1px solid var(--line);
    border-radius:16px;
    padding:22px;
    text-align:center;
    min-width:0;
}

.hero-card img{
    width:100%;
    max-width:420px;
    max-height:420px;
    object-fit:contain;
    margin:auto;
}

.hero-logo{
    width:100%;
    min-height:360px;
    display:flex;
    align-items:center;
    justify-content:center;
    overflow:hidden;
}

.hero-logo img{
    display:block;
    width:auto;
    height:auto;
    max-width:100%;
    max-height:360px;
    object-fit:contain;
}

/* =========================================================
   SECTIONS
   ========================================================= */

.section{
    padding:46px 0;
}

.section-head{
    display:flex;
    justify-content:space-between;
    gap:20px;
    align-items:flex-end;
    margin-bottom:22px;
    min-width:0;
}

.section h2{
    margin:0;
    color:var(--dark);
    font-size:28px;
    line-height:1.25;
}

/* =========================================================
   GRIDS
   ========================================================= */

.grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:18px;
}

.grid-4{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:16px;
}

.two{
    display:grid;
    grid-template-columns:minmax(0,2fr) minmax(280px,1fr);
    gap:18px;
}

/* =========================================================
   CARDS
   ========================================================= */

.card{
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    padding:20px;
    min-width:0;
}

.card h3{
    margin:0 0 8px;
    color:var(--dark);
}

.iconbox{
    width:42px;
    height:42px;
    border-radius:10px;
    background:#eef6ff;
    color:var(--primary);
    display:grid;
    place-items:center;
    font-weight:800;
    margin-bottom:12px;
}

/* =========================================================
   BUTTONS
   ========================================================= */

.btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:7px;
    min-height:42px;
    border:0;
    background:var(--primary);
    color:#fff!important;
    border-radius:8px;
    padding:10px 16px;
    font-weight:700;
    cursor:pointer;
    text-align:center;
    transition:
        background .18s ease,
        transform .18s ease,
        box-shadow .18s ease;
}

.btn:hover{
    background:#0b4e9f;
}

.btn:active{
    transform:translateY(1px);
}

.btn.alt{
    background:#eef6ff;
    color:#0b4e9f!important;
}

.btn.outline{
    background:#fff;
    color:var(--primary)!important;
    border:1px solid #b8cff0;
}

.btn.danger{
    background:#fff0ef;
    color:var(--danger)!important;
}

/* =========================================================
   PRICE / TEXT
   ========================================================= */

.price{
    font-size:22px;
    font-weight:800;
    color:var(--dark);
}

.muted{
    color:var(--muted);
}

/* =========================================================
   FORMS
   ========================================================= */

.form{
    width:100%;
    max-width:680px;
    margin:30px auto;
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    padding:25px;
}

.form-wide{
    max-width:900px;
}

.form-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:0 18px;
}

.full{
    grid-column:1/-1;
}

label{
    font-weight:700;
    display:block;
    margin:13px 0 6px;
}

input,
select,
textarea{
    width:100%;
    min-width:0;
    border:1px solid #d0d5dd;
    border-radius:8px;
    padding:10px 11px;
    font:inherit;
    background:#fff;
    color:var(--text);
    outline:none;
}

input:focus,
select:focus,
textarea:focus{
    border-color:#8eb6eb;
    box-shadow:0 0 0 3px rgba(15,95,196,.10);
}

textarea{
    min-height:135px;
    resize:vertical;
}

/* =========================================================
   ALERTS
   ========================================================= */

.alert{
    padding:12px 14px;
    border-radius:8px;
    margin:12px 0;
    overflow-wrap:anywhere;
}

.error{
    background:#fef3f2;
    color:var(--danger);
}

.success{
    background:#ecfdf3;
    color:var(--success);
}

.warning{
    background:#fffaeb;
    color:var(--warning);
}

/* =========================================================
   TOOLBAR
   ========================================================= */

.toolbar{
    display:flex;
    justify-content:space-between;
    gap:12px;
    align-items:center;
    margin-bottom:18px;
    min-width:0;
}

.toolbar > *{
    min-width:0;
}

/* =========================================================
   TABLES
   ========================================================= */

.table{
    width:100%;
    overflow-x:auto;
    overflow-y:hidden;
    -webkit-overflow-scrolling:touch;
    background:#fff;
    border:1px solid var(--line);
    border-radius:10px;
}

table{
    width:100%;
    border-collapse:collapse;
}

th,
td{
    padding:11px;
    border-bottom:1px solid var(--line);
    text-align:left;
    white-space:nowrap;
}

th{
    background:#f8fafc;
}

/* Tables remain usable on narrow devices instead of
   breaking the entire page horizontally. */

.table table{
    min-width:620px;
}

/* =========================================================
   FOOTER
   ========================================================= */

footer{
    background:#fff;
    border-top:1px solid var(--line);
    margin-top:45px;
}

.foot{
    padding:34px 0 20px;
    display:grid;
    grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) minmax(0,1fr);
    gap:25px;
}

.foot h4{
    margin:0 0 9px;
    color:var(--dark);
}

.foot a{
    display:block;
    color:var(--muted);
    margin:4px 0;
}

.foot a:hover{
    color:var(--primary);
}

.copyright{
    border-top:1px solid var(--line);
    padding:14px 0;
    color:var(--muted);
    font-size:13px;
}

/* =========================================================
   BADGES / NOTICES / FAQ
   ========================================================= */

.badge{
    display:inline-flex;
    align-items:center;
    max-width:100%;
    padding:4px 8px;
    border-radius:999px;
    background:#eef2f6;
    font-size:12px;
    overflow-wrap:anywhere;
}

.ticket{
    border-left:4px solid var(--primary);
}

.notice{
    background:#eef6ff;
    border:1px solid #c9def8;
    padding:15px;
    border-radius:10px;
    overflow-wrap:anywhere;
}

.faq details{
    background:#fff;
    border:1px solid var(--line);
    border-radius:10px;
    padding:14px 16px;
    margin:10px 0;
}

.faq summary{
    font-weight:700;
    cursor:pointer;
    color:var(--dark);
}

/* =========================================================
   ADMIN LAYOUT
   ========================================================= */

.admin{
    display:grid;
    grid-template-columns:225px minmax(0,1fr);
    min-height:80vh;
}

.side{
    background:#fff;
    border-right:1px solid var(--line);
    padding:18px;
    min-width:0;
}

.side a{
    display:block;
    padding:10px;
    border-radius:7px;
    margin:3px 0;
}

.side a:hover{
    background:#f0f5fa;
    color:var(--primary);
}

.main{
    padding:25px;
    min-width:0;
}

.stats{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:15px;
}

.stat{
    background:#fff;
    border:1px solid var(--line);
    border-radius:10px;
    padding:18px;
    min-width:0;
}

.stat strong{
    display:block;
    font-size:27px;
    overflow-wrap:anywhere;
}

.empty{
    padding:35px;
    text-align:center;
    color:var(--muted);
}

/* =========================================================
   CUSTOMER ACCOUNT DASHBOARD
   ========================================================= */

.account-hero{
    background:#fff;
    border-bottom:1px solid var(--line);
    padding:38px 0;
}

.account-hero-inner{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:25px;
    min-width:0;
}

.account-hero h1{
    margin:5px 0 7px;
    color:var(--dark);
    font-size:34px;
}

.account-hero p{
    margin:0;
    color:var(--muted);
    font-size:16px;
}

.account-actions{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
}

.account-section{
    padding-top:30px;
}

.account-layout{
    display:grid;
    grid-template-columns:245px minmax(0,1fr);
    gap:20px;
    align-items:start;
}

.account-sidebar{
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    overflow:hidden;
    min-width:0;
}

.account-profile{
    padding:22px 18px;
    text-align:center;
    border-bottom:1px solid var(--line);
}

.account-profile h3{
    margin:10px 0 3px;
    color:var(--dark);
}

.account-profile p{
    margin:2px 0;
    font-size:13px;
}

.profile-avatar{
    width:66px;
    height:66px;
    margin:0 auto;
    border-radius:50%;
    display:grid;
    place-items:center;
    background:linear-gradient(135deg,#0f5fc4,#11b8c8);
    color:#fff;
    font-size:25px;
    font-weight:800;
}

.account-nav{
    padding:10px;
}

.account-nav a{
    display:block;
    padding:10px 12px;
    border-radius:8px;
    color:#344054;
    font-weight:600;
    margin:2px 0;
}

.account-nav a:hover,
.account-nav a.active{
    background:#eef6ff;
    color:var(--primary);
}

.account-nav a.logout-link{
    color:var(--danger);
    margin-top:8px;
    border-top:1px solid var(--line);
    border-radius:0;
    padding-top:13px;
}

.account-nav a.logout-link:hover{
    background:#fff0ef;
}

.account-main{
    min-width:0;
}

.account-stats{
    grid-template-columns:repeat(4,minmax(0,1fr));
    margin-bottom:20px;
}

.account-stat{
    display:block;
    color:inherit;
    transition:
        box-shadow .15s ease,
        border-color .15s ease;
}

.account-stat:hover{
    border-color:#b8cff0;
    box-shadow:0 4px 14px rgba(16,42,67,.06);
}

.account-stat .stat-label{
    display:block;
    color:var(--muted);
    font-size:13px;
    font-weight:700;
}

.account-stat strong{
    margin:4px 0;
    font-size:28px;
    color:var(--dark);
}

.account-stat .stat-link{
    font-size:12px;
    color:var(--primary);
    font-weight:700;
}

.account-panels{
    display:grid;
    gap:20px;
}

.compact-head{
    margin-bottom:15px;
}

.compact-head h2{
    font-size:22px;
    margin-top:2px;
}

.account-table{
    border-radius:9px;
}

.account-table table{
    min-width:720px;
}

.account-table th,
.account-table td{
    font-size:13px;
}

.status-paid,
.status-completed{
    background:#ecfdf3;
    color:var(--success);
}

.status-pending,
.status-processing{
    background:#fffaeb;
    color:var(--warning);
}

.status-failed,
.status-cancelled,
.status-refunded{
    background:#fef3f2;
    color:var(--danger);
}

.account-help-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:18px;
}

.help-card{
    height:100%;
}

.help-card .btn{
    margin-top:8px;
}

.account-empty{
    background:#f8fafc;
    border:1px dashed #cbd5e1;
    border-radius:10px;
    padding:20px;
}

.account-empty h3{
    margin:0 0 5px;
    color:var(--dark);
}

.account-empty p{
    margin:0 0 15px;
}

.account-hero .btn.outline{
    color:var(--primary)!important;
}

/* =========================================================
   RESPONSIVE — LARGE TABLETS / SMALL LAPTOPS
   ========================================================= */

@media (max-width:1100px){

    .container{
        width:min(var(--container),calc(100% - 28px));
    }

    .hero-grid{
        grid-template-columns:minmax(0,1.2fr) minmax(250px,.8fr);
        gap:25px;
    }

    .grid-4{
        grid-template-columns:repeat(3,minmax(0,1fr));
    }

    .stats{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .account-stats{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .account-layout{
        grid-template-columns:220px minmax(0,1fr);
    }
}

/* =========================================================
   RESPONSIVE — TABLET
   ========================================================= */

@media (max-width:900px){

    .hero-grid{
        grid-template-columns:1fr;
    }

    .hero-copy{
        min-width:0;
    }

    .hero-card,
    .hero-logo{
        max-width:650px;
        margin-left:auto;
        margin-right:auto;
    }

    .grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .grid-4{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .two{
        grid-template-columns:1fr;
    }

    .contact-mini{
        display:none;
    }

    .admin{
        grid-template-columns:1fr;
    }

    .side{
        border-right:0;
        border-bottom:1px solid var(--line);
    }

    .main{
        padding:22px;
    }

    .foot{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .account-layout{
        grid-template-columns:1fr;
    }

    .account-sidebar{
        display:grid;
        grid-template-columns:230px minmax(0,1fr);
        align-items:stretch;
    }

    .account-profile{
        border-bottom:0;
        border-right:1px solid var(--line);
    }

    .account-nav{
        display:flex;
        align-items:center;
        gap:5px;
        flex-wrap:wrap;
    }

    .account-nav a{
        flex:0 0 auto;
    }

    .account-nav a.logout-link{
        border-top:0;
        margin-top:2px;
        padding-top:10px;
    }

    .account-help-grid{
        grid-template-columns:1fr 1fr;
    }

    .hero-logo{
        min-height:280px;
    }

    .hero-logo img{
        max-height:280px;
    }
}

/* =========================================================
   RESPONSIVE — SMALL TABLET / LARGE PHONE
   ========================================================= */

@media (max-width:768px){

    body{
        font-size:14px;
    }

    .container{
        width:calc(100% - 28px);
    }

    .nav{
        min-height:auto;
        align-items:flex-start;
        padding:10px 0;
        flex-wrap:wrap;
    }

    .brand{
        min-width:0;
    }

    .brand img{
        width:45px;
        height:45px;
    }

    .brand-text{
        font-size:14px;
    }

    .brand-text small{
        font-size:9px;
    }

    .navlinks{
        width:100%;
        justify-content:flex-start;
        gap:7px 10px;
        margin-left:0;
    }

    .navlinks a{
        font-size:13px;
    }

    .hero{
        padding:48px 0;
    }

    .hero h1{
        font-size:clamp(30px,7vw,38px);
    }

    .hero p{
        font-size:15px;
    }

    .section{
        padding:38px 0;
    }

    .section h2{
        font-size:24px;
    }

    .section-head{
        display:block;
    }

    .section-head > * + *{
        margin-top:12px;
    }

    .form{
        padding:20px;
    }

    .toolbar{
        display:block;
    }

    .toolbar > * + *{
        margin-top:12px;
    }

    .account-hero{
        padding:30px 0;
    }

    .account-hero-inner{
        display:block;
    }

    .account-actions{
        margin-top:18px;
    }

    .account-help-grid{
        grid-template-columns:1fr;
    }

    .account-sidebar{
        display:block;
    }

    .account-profile{
        border-right:0;
        border-bottom:1px solid var(--line);
    }

    .account-nav{
        display:block;
    }

    .account-nav a{
        width:100%;
    }

    .account-nav a.logout-link{
        border-top:1px solid var(--line);
        margin-top:8px;
        padding-top:13px;
    }
}

/* =========================================================
   RESPONSIVE — MOBILE
   ========================================================= */

@media (max-width:650px){

    .container{
        width:calc(100% - 24px);
    }

    .grid,
    .grid-4,
    .stats,
    .form-grid,
    .foot{
        grid-template-columns:1fr;
    }

    .full{
        grid-column:auto;
    }

    .hero{
        padding:38px 0 34px;
    }

    .hero h1{
        font-size:32px;
        line-height:1.15;
    }

    .hero p{
        font-size:14px;
    }

    .hero-logo{
        min-height:220px;
        padding:15px;
    }

    .hero-logo img{
        max-height:220px;
    }

    .hero-card{
        padding:15px;
    }

    .actions,
    .hero-actions,
    .account-actions{
        width:100%;
    }

    .actions .btn,
    .hero-actions .btn,
    .account-actions .btn{
        flex:1 1 100%;
        width:100%;
    }

    .card{
        padding:17px;
    }

    .form{
        margin:20px auto;
        padding:17px;
        border-radius:10px;
    }

    input,
    select,
    textarea{
        font-size:16px;
    }

    .btn{
        width:100%;
        min-height:44px;
    }

    .navlinks .btn{
        width:auto;
    }

    .toolbar{
        margin-bottom:14px;
    }

    .table{
        border-radius:8px;
    }

    .table table{
        min-width:600px;
    }

    .account-table{
        margin-left:-3px;
        margin-right:-3px;
    }

    .account-table table{
        min-width:700px;
    }

    .account-stats{
        grid-template-columns:1fr;
    }

    .account-hero h1{
        font-size:29px;
    }

    .account-hero p{
        font-size:14px;
    }

    .main{
        padding:17px 12px;
    }

    .side{
        padding:12px;
    }

    .stat{
        padding:16px;
    }

    .stat strong{
        font-size:24px;
    }

    .foot{
        padding-top:28px;
        gap:20px;
    }

    .copyright{
        font-size:12px;
    }
}

/* =========================================================
   RESPONSIVE — VERY SMALL PHONES
   ========================================================= */

@media (max-width:420px){

    .container{
        width:calc(100% - 20px);
    }

    .brand{
        gap:7px;
    }

    .brand img{
        width:40px;
        height:40px;
    }

    .brand-text{
        font-size:13px;
    }

    .navlinks{
        gap:6px;
    }

    .navlinks a{
        font-size:12px;
    }

    .hero h1{
        font-size:28px;
    }

    .hero-logo{
        min-height:190px;
    }

    .hero-logo img{
        max-height:190px;
    }

    .section h2{
        font-size:22px;
    }

    .form{
        padding:14px;
    }

    .card{
        padding:15px;
    }

    .empty{
        padding:25px 15px;
    }
}

/* =========================================================
   TOUCH DEVICES
   ========================================================= */

@media (hover:none){

    .btn:hover{
        background:var(--primary);
    }

    .navlinks a:hover{
        color:inherit;
    }

    .account-stat:hover{
        border-color:var(--line);
        box-shadow:none;
    }
}

/* =========================================================
   ACCESSIBILITY / REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion:reduce){

    html{
        scroll-behavior:auto;
    }

    *,
    *::before,
    *::after{
        animation-duration:.01ms!important;
        animation-iteration-count:1!important;
        transition-duration:.01ms!important;
        scroll-behavior:auto!important;
    }
}

/* =========================================================
   PRINT
   ========================================================= */

@media print{

    .header,
    .navlinks,
    .actions,
    .hero-actions,
    .account-actions,
    .side,
    footer{
        display:none!important;
    }

    body{
        background:#fff;
        color:#000;
        overflow:visible;
    }

    .container{
        width:100%;
        max-width:none;
    }

    .main{
        padding:0;
    }

    .card,
    .form,
    .table{
        box-shadow:none;
        border-color:#ccc;
    }
}