﻿/* ============================================================
   PCYako — Main Stylesheet
   Theme: Dark navy + electric blue accent
   ============================================================ */

/* ── CSS Variables ─────────────────────────────────────────── */
:root {
    --bg:           #0d1117;
    --bg-surface:   #161b22;
    --bg-card:      #1c2230;
    --bg-input:     #0d1117;
    --border:       #30363d;
    --border-focus: #3b82f6;

    --text:         #e6edf3;
    --text-muted:   #8b949e;
    --text-subtle:  #545d68;

    --accent:       #3b82f6;
    --accent-dark:  #1d4ed8;
    --accent-hover: #60a5fa;
    --accent-glow:  rgba(59, 130, 246, 0.25);

    --success: #22c55e;
    --danger:  #ef4444;
    --warning: #f59e0b;
    --info:    #06b6d4;

    --radius:   10px;
    --radius-sm: 6px;
    --shadow:   0 4px 24px rgba(0,0,0,.4);
    --shadow-sm:0 2px 8px rgba(0,0,0,.25);

    --font: 'Inter', system-ui, -apple-system, sans-serif;
    --transition: 150ms ease;
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }
img, svg { max-width: 100%; }
ul { list-style: none; }

/* ── Container ──────────────────────────────────────────────── */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

/* ── Typography ─────────────────────────────────────────────── */
h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 700; line-height: 1.15; }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 600; }
h3 { font-size: 1.25rem; font-weight: 600; }
h4 { font-size: 1rem;    font-weight: 600; }
p  { color: var(--text-muted); }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .625rem 1.25rem;
    border-radius: var(--radius-sm);
    font-size: .9rem;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background var(--transition), opacity var(--transition), transform var(--transition);
    white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary  { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-ghost  { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-sm { padding: .4rem .9rem; font-size: .82rem; }
.btn-lg { padding: .85rem 2rem; font-size: 1rem; }
.btn-block { width: 100%; justify-content: center; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ── Forms ──────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.25rem; }
.form-label {
    display: block;
    margin-bottom: .4rem;
    font-size: .875rem;
    font-weight: 500;
    color: var(--text);
}
.form-label span { color: var(--danger); margin-left: 2px; }
.form-control {
    width: 100%;
    padding: .625rem .875rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: .9rem;
    font-family: var(--font);
    transition: border-color var(--transition), box-shadow var(--transition);
}
.form-control:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}
.form-control::placeholder { color: var(--text-subtle); }
textarea.form-control { resize: vertical; min-height: 120px; }
select.form-control { cursor: pointer; }
.form-hint { font-size: .78rem; color: var(--text-muted); margin-top: .3rem; }
.form-error { font-size: .82rem; color: var(--danger); margin-top: .3rem; }
.input-group { position: relative; }
.input-group .form-control { padding-right: 2.5rem; }
.input-group .input-icon {
    position: absolute; right: .75rem; top: 50%; transform: translateY(-50%);
    color: var(--text-subtle); cursor: pointer; user-select: none;
}

/* ── Alerts ─────────────────────────────────────────────────── */
.alert {
    padding: .875rem 1rem;
    border-radius: var(--radius-sm);
    font-size: .875rem;
    margin-bottom: 1.25rem;
    border-left: 3px solid currentColor;
}
.alert-success { background: rgba(34,197,94,.1);  color: var(--success); }
.alert-danger   { background: rgba(239,68,68,.1);  color: var(--danger);  }
.alert-warning  { background: rgba(245,158,11,.1); color: var(--warning); }
.alert-info     { background: rgba(6,182,212,.1);  color: var(--info);    }

/* ── Cards ──────────────────────────────────────────────────── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem;
}
.card-header { margin-bottom: 1.5rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border); }
.card-title { font-size: 1.1rem; font-weight: 600; }

/* ── Badge ──────────────────────────────────────────────────── */
.badge {
    display: inline-flex; align-items: center;
    padding: .2rem .6rem; border-radius: 999px;
    font-size: .72rem; font-weight: 600; letter-spacing: .03em;
}
.badge-success { background: rgba(34,197,94,.15); color: var(--success); }
.badge-danger  { background: rgba(239,68,68,.15); color: var(--danger); }
.badge-warning { background: rgba(245,158,11,.15); color: var(--warning); }
.badge-info    { background: rgba(6,182,212,.15);  color: var(--info); }
.badge-neutral { background: rgba(139,148,158,.15);color: var(--text-muted); }

/* ── Navbar ─────────────────────────────────────────────────── */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(13,17,23,.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.navbar {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px; gap: 1rem;
}
.brand { display: flex; align-items: center; gap: .6rem; color: var(--text); font-weight: 700; font-size: 1.15rem; }
.brand:hover { color: var(--text); }
.brand-icon { width: 32px; height: 32px; flex-shrink: 0; }

.nav-links {
    display: flex; align-items: center; gap: .25rem;
}
.nav-link { padding: .4rem .7rem; border-radius: var(--radius-sm); color: var(--text-muted); font-size: .875rem; }
.nav-link:hover { color: var(--text); background: rgba(255,255,255,.07); }
.nav-divider { width: 1px; height: 20px; background: var(--border); margin: 0 .5rem; }
.nav-user {
    display: flex; align-items: center; gap: .5rem;
    position: relative; cursor: pointer; padding: .3rem .5rem;
    border-radius: var(--radius-sm);
}
.nav-user:hover { background: rgba(255,255,255,.07); }
.nav-user span { font-size: .875rem; }
.avatar {
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--accent); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: .75rem; font-weight: 600;
}
.user-dropdown {
    display: none; position: absolute; top: calc(100% + 6px); right: 0;
    background: var(--bg-surface); border: 1px solid var(--border);
    border-radius: var(--radius-sm); box-shadow: var(--shadow);
    min-width: 150px; overflow: hidden;
}
.user-dropdown a {
    display: block; padding: .6rem 1rem; font-size: .875rem;
    color: var(--text); border-bottom: 1px solid var(--border);
}
.user-dropdown a:last-child { border-bottom: none; }
.user-dropdown a:hover { background: rgba(255,255,255,.06); }
.user-dropdown a.danger { color: var(--danger); }
.nav-user:hover .user-dropdown, .nav-user:focus-within .user-dropdown { display: block; }

.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: .3rem; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: var(--transition); }

/* ── Page Main ──────────────────────────────────────────────── */
.page-main { flex: 1; }

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
    padding: 6rem 0 5rem;
    text-align: center;
    background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(59,130,246,.18), transparent);
}
.hero-eyebrow {
    display: inline-flex; align-items: center; gap: .5rem;
    background: rgba(59,130,246,.12); border: 1px solid rgba(59,130,246,.3);
    color: var(--accent); padding: .3rem .85rem; border-radius: 999px;
    font-size: .8rem; font-weight: 500; margin-bottom: 1.5rem;
}
.hero h1 { margin-bottom: 1.5rem; }
.hero .lead { font-size: 1.1rem; max-width: 540px; margin: 0 auto 2.5rem; }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.hero-preview {
    margin-top: 4rem;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .5rem;
    max-width: 820px; margin-left: auto; margin-right: auto;
    box-shadow: var(--shadow), 0 0 80px rgba(59,130,246,.08);
}
.hero-preview-bar {
    display: flex; align-items: center; gap: .5rem;
    padding: .5rem .75rem; border-bottom: 1px solid var(--border); margin-bottom: .5rem;
}
.preview-dot { width: 11px; height: 11px; border-radius: 50%; }

/* ── Features Section ───────────────────────────────────────── */
.section { padding: 5rem 0; }
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-header h2 { margin-bottom: .75rem; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.feature-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem;
    transition: border-color var(--transition), transform var(--transition);
}
.feature-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.feature-icon {
    width: 44px; height: 44px;
    background: var(--accent-glow);
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem; margin-bottom: 1rem; color: var(--accent);
}
.feature-card h3 { margin-bottom: .5rem; }

/* ── Pricing ────────────────────────────────────────────────── */
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.5rem; }
.pricing-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem 1.5rem;
    display: flex; flex-direction: column;
    transition: border-color var(--transition);
}
.pricing-card.featured {
    border-color: var(--accent);
    background: linear-gradient(160deg, rgba(59,130,246,.07), var(--bg-surface));
}
.pricing-card .plan-name { font-weight: 700; font-size: 1.1rem; margin-bottom: .5rem; }
.pricing-card .plan-price { font-size: 2.25rem; font-weight: 700; margin: 1rem 0; }
.pricing-card .plan-price sup { font-size: 1rem; font-weight: 500; vertical-align: super; }
.pricing-card .plan-price span { font-size: .9rem; font-weight: 400; color: var(--text-muted); }
.pricing-card ul { margin: 1rem 0 1.5rem; flex: 1; }
.pricing-card ul li { padding: .4rem 0; color: var(--text-muted); font-size: .875rem; display: flex; align-items: center; gap: .5rem; }
.pricing-card ul li::before { content: '✓'; color: var(--success); font-weight: 700; }

/* ── Auth Pages ─────────────────────────────────────────────── */
.auth-wrapper {
    min-height: calc(100vh - 64px);
    display: flex; align-items: center; justify-content: center;
    padding: 2rem 1rem;
}
.auth-card {
    width: 100%; max-width: 440px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem;
}
.auth-logo { text-align: center; margin-bottom: 1.75rem; }
.auth-logo .brand { justify-content: center; font-size: 1.3rem; }
.auth-title { font-size: 1.4rem; font-weight: 700; text-align: center; margin-bottom: .35rem; }
.auth-subtitle { text-align: center; font-size: .875rem; color: var(--text-muted); margin-bottom: 2rem; }
.auth-footer { text-align: center; margin-top: 1.5rem; font-size: .875rem; color: var(--text-muted); }
.auth-divider {
    display: flex; align-items: center; gap: .75rem; margin: 1.5rem 0;
    color: var(--text-subtle); font-size: .8rem;
}
.auth-divider::before, .auth-divider::after {
    content: ''; flex: 1; height: 1px; background: var(--border);
}

/* ── Dashboard ──────────────────────────────────────────────── */
.page-hero {
    background: linear-gradient(135deg, var(--bg-surface) 0%, var(--bg-card) 100%);
    border-bottom: 1px solid var(--border);
    padding: 2rem 0 1.75rem;
}
.page-hero h1 { font-size: 1.65rem; }
.page-hero p   { margin-top: .3rem; font-size: .9rem; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.25rem; margin: 2rem 0; }
.stat-card {
    background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
}
.stat-card .stat-label { font-size: .8rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; }
.stat-card .stat-value { font-size: 2rem; font-weight: 700; margin-top: .25rem; }
.stat-card .stat-sub   { font-size: .8rem; color: var(--text-muted); margin-top: .25rem; }

.dashboard-grid { display: grid; grid-template-columns: 1fr 340px; gap: 1.5rem; margin-top: 2rem; }
@media (max-width: 900px) { .dashboard-grid { grid-template-columns: 1fr; } }

/* ── Table ──────────────────────────────────────────────────── */
.table-wrapper { overflow-x: auto; border-radius: var(--radius-sm); }
.data-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.data-table th {
    text-align: left; padding: .75rem 1rem;
    background: var(--bg-surface); color: var(--text-muted);
    font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em;
    border-bottom: 1px solid var(--border);
}
.data-table td { padding: .85rem 1rem; border-bottom: 1px solid rgba(48,54,61,.5); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: rgba(255,255,255,.025); }

/* ── Device Card ────────────────────────────────────────────── */
.devices-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; margin-top: 1.5rem; }
.device-card {
    background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.5rem; display: flex; flex-direction: column; gap: .75rem;
    transition: border-color var(--transition);
}
.device-card:hover { border-color: var(--accent); }
.device-header { display: flex; align-items: center; gap: .75rem; }
.device-icon {
    width: 44px; height: 44px; border-radius: var(--radius-sm);
    background: var(--accent-glow); display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem; color: var(--accent); flex-shrink: 0;
}
.device-id { font-family: monospace; font-size: .85rem; color: var(--text-muted);
             letter-spacing: .1em; background: var(--bg-surface);
             padding: .25rem .6rem; border-radius: var(--radius-sm); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.status-online  { background: var(--success); box-shadow: 0 0 6px var(--success); }
.status-offline { background: var(--text-subtle); }
.status-busy    { background: var(--warning); }

/* ── Feedback Form ──────────────────────────────────────────── */
.feedback-wrapper { max-width: 700px; margin: 0 auto; padding: 3rem 1rem; }
.star-rating { display: flex; gap: .35rem; flex-direction: row-reverse; justify-content: flex-end; }
.star-rating input { display: none; }
.star-rating label { font-size: 1.8rem; cursor: pointer; color: var(--text-subtle); transition: color var(--transition); }
.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label { color: var(--warning); }

/* ── Profile ────────────────────────────────────────────────── */
.profile-wrapper { max-width: 760px; margin: 0 auto; padding: 2.5rem 1rem 4rem; }
.profile-avatar-section { display: flex; align-items: center; gap: 1.5rem; margin-bottom: 2rem; }
.avatar-lg {
    width: 72px; height: 72px; border-radius: 50%;
    background: var(--accent); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.75rem; font-weight: 700;
}

/* ── Sessions History ───────────────────────────────────────── */
.sessions-wrapper { padding: 2rem 0 4rem; }

/* ── Password strength ──────────────────────────────────────── */
.strength-bar { height: 4px; border-radius: 999px; background: var(--border); margin-top: .5rem; overflow: hidden; }
.strength-fill { height: 100%; border-radius: 999px; transition: width .3s, background .3s; }

/* ── Footer ─────────────────────────────────────────────────── */
.site-footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    padding: 3.5rem 0 0;
    margin-top: auto;
}
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 2rem; }
.footer-brand .brand-name { font-size: 1.2rem; font-weight: 700; display: block; margin-bottom: .5rem; }
.footer-brand p { font-size: .875rem; }
.footer-col h4 { font-size: .875rem; color: var(--text); margin-bottom: 1rem; }
.footer-col ul li { margin-bottom: .5rem; }
.footer-col ul li a { color: var(--text-muted); font-size: .875rem; }
.footer-col ul li a:hover { color: var(--text); }
.footer-bottom {
    display: flex; justify-content: space-between; align-items: center;
    padding: 1.5rem 0; margin-top: 2.5rem;
    border-top: 1px solid var(--border);
    font-size: .8rem; color: var(--text-subtle);
}

/* ── Utility ────────────────────────────────────────────────── */
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.text-muted  { color: var(--text-muted); }
.text-sm     { font-size: .875rem; }
.text-right  { text-align: right; }
.mono        { font-family: monospace; }
.w-full      { width: 100%; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 768px) {
    .nav-links { display: none; flex-direction: column; align-items: stretch; position: absolute;
                 top: 64px; left: 0; right: 0; background: var(--bg-surface);
                 border-bottom: 1px solid var(--border); padding: .75rem 1rem; gap: .25rem; }
    .nav-links.open { display: flex; }
    .hamburger { display: flex; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .footer-bottom { flex-direction: column; gap: .5rem; text-align: center; }
    .hero { padding: 4rem 0 3.5rem; }
    .auth-card { padding: 1.75rem; }
}
@media (max-width: 480px) {
    .footer-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
}
