/* ================================================
   Hotel Csopak Jelenléti Ív – Dolgozói felület
   v1.0 — WordPress téma izoláció + iPad design
   ================================================ */

/* ── CSS változók ── */
.hcji-wrap {
    --hc-gold:       #B8962E;
    --hc-gold-lt:    #D4AF55;
    --hc-gold-dk:    #7A5F18;
    --hc-blue:       #2E5B8C;
    --hc-bg:         #FAF7F2;
    --hc-card:       #FFFFFF;
    --hc-text:       #2C2416;
    --hc-muted:      #8A7E6E;
    --hc-border:     #E2D8C8;
    --hc-green:      #2D7A4F;
    --hc-red:        #B83232;
    --hc-radius:     14px;
    --hc-shadow:     0 2px 16px rgba(0,0,0,.07);
    --hc-font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
    --hc-font-sans:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ── TÉMA RESET: minden elem a .hcji-wrap-on belül ── */
.hcji-wrap,
.hcji-wrap *,
.hcji-wrap *::before,
.hcji-wrap *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.hcji-wrap {
    font-family: var(--hc-font-sans);
    font-size: 16px;
    line-height: 1.5;
    color: var(--hc-text);
    background: var(--hc-bg);
    -webkit-font-smoothing: antialiased;
    min-height: 400px;
    width: 100%;
}

/* Téma button/input/a reset a plugin elemein belül */
.hcji-wrap button {
    all: unset;
    box-sizing: border-box;
    cursor: pointer;
    font-family: var(--hc-font-sans);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.hcji-wrap input {
    all: unset;
    box-sizing: border-box;
    font-family: var(--hc-font-sans);
    display: block;
}
.hcji-wrap a {
    color: var(--hc-blue);
    text-decoration: none;
}
.hcji-wrap h2 {
    all: unset;
    box-sizing: border-box;
    display: block;
}
.hcji-wrap select {
    font-family: var(--hc-font-sans);
    font-size: 14px;
}

/* ── Belső konténer ── */
#hcji-login-screen,
#hcji-dashboard {
    max-width: 720px;
    margin: 0 auto;
    padding: 28px 20px 60px;
}

/* ════════════════════════════════════════════════
   FEJLÉC
   ════════════════════════════════════════════ */
.hcji-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--hc-border);
    margin-bottom: 28px;
}
.hcji-hotel-name {
    font-family: var(--hc-font-serif);
    font-size: 22px;
    font-weight: 700;
    color: var(--hc-gold);
    letter-spacing: .3px;
    line-height: 1.2;
}
.hcji-header-sub {
    font-size: 12px;
    color: var(--hc-muted);
    margin-top: 3px;
}
.hcji-logout-btn {
    border: 1px solid var(--hc-border) !important;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 13px;
    color: var(--hc-muted);
    background: transparent;
    transition: border-color .2s, color .2s;
    white-space: nowrap;
}
.hcji-logout-btn:hover {
    border-color: var(--hc-red) !important;
    color: var(--hc-red);
}

/* ════════════════════════════════════════════════
   KÁRTYÁK
   ════════════════════════════════════════════ */
.hcji-card {
    background: var(--hc-card);
    border: 1px solid var(--hc-border);
    border-radius: var(--hc-radius);
    padding: 24px;
    box-shadow: var(--hc-shadow);
    margin-bottom: 14px;
}

/* ════════════════════════════════════════════════
   LOGIN – 1. LÉPÉS (névlista)
   ════════════════════════════════════════════ */
.hcji-step-title {
    font-family: var(--hc-font-serif) !important;
    font-size: 28px !important;
    font-weight: 600 !important;
    color: var(--hc-text) !important;
    text-align: center;
    margin-bottom: 28px !important;
    line-height: 1.3 !important;
}

.hcji-search-wrap {
    margin-bottom: 16px;
}
.hcji-search-input {
    width: 100%;
    padding: 15px 18px !important;
    border: 1.5px solid var(--hc-border) !important;
    border-radius: 12px;
    font-size: 16px;
    background: #fff;
    color: var(--hc-text);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    display: block !important;
    -webkit-appearance: none;
}
.hcji-search-input:focus {
    border-color: var(--hc-gold) !important;
    box-shadow: 0 0 0 3px rgba(184,150,46,.12);
}
.hcji-search-input::placeholder {
    color: var(--hc-muted);
}

.hcji-employee-list {
    border: 1.5px solid var(--hc-border);
    border-radius: 14px;
    background: #fff;
    max-height: 420px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 2px 10px rgba(0,0,0,.04);
}
.hcji-emp-category {
    padding: 9px 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.3px;
    color: var(--hc-muted);
    background: var(--hc-bg);
    border-bottom: 1px solid var(--hc-border);
    position: sticky;
    top: 0;
    z-index: 1;
}
.hcji-emp-item {
    display: flex !important;
    align-items: center;
    padding: 18px 22px;
    cursor: pointer;
    border-bottom: 1px solid var(--hc-border);
    transition: background .12s;
    min-height: 68px;
    user-select: none;
    -webkit-tap-highlight-color: rgba(0,0,0,.04);
    width: 100%;
    background: transparent;
    text-align: left;
    gap: 12px;
}
.hcji-emp-item:last-child {
    border-bottom: none;
}
.hcji-emp-item:hover,
.hcji-emp-item:active {
    background: #f9f5ed !important;
}
.hcji-emp-item-name {
    font-size: 17px;
    font-weight: 500;
    color: var(--hc-text);
    flex: 1;
    line-height: 1.3;
}
.hcji-emp-item-arrow {
    color: var(--hc-border);
    font-size: 24px;
    line-height: 1;
    font-weight: 300;
    flex-shrink: 0;
}

.hcji-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px 32px;
    color: var(--hc-muted);
    font-size: 15px;
}
.hcji-spinner {
    display: inline-block;
    width: 22px;
    height: 22px;
    border: 2px solid var(--hc-border);
    border-top-color: var(--hc-gold);
    border-radius: 50%;
    animation: hcji-spin .7s linear infinite;
    flex-shrink: 0;
}
@keyframes hcji-spin { to { transform: rotate(360deg); } }

/* ════════════════════════════════════════════════
   LOGIN – 2. LÉPÉS (PIN)
   ════════════════════════════════════════════ */
.hcji-back-btn {
    background: none !important;
    border: none !important;
    color: var(--hc-blue) !important;
    font-size: 15px;
    cursor: pointer;
    padding: 8px 2px;
    margin-bottom: 22px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: var(--hc-font-sans);
    opacity: .85;
    transition: opacity .15s;
}
.hcji-back-btn:hover {
    opacity: 1;
}

.hcji-selected-name {
    text-align: center;
    font-size: 22px;
    font-family: var(--hc-font-serif);
    color: var(--hc-gold-dk);
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.3;
    padding: 16px 20px;
    background: linear-gradient(135deg, #fdf6e7, #faf7f2);
    border: 1px solid rgba(184,150,46,.2);
    border-radius: 12px;
}
.hcji-pin-subtitle {
    text-align: center;
    font-size: 13px;
    color: var(--hc-muted);
    margin-bottom: 28px;
    margin-top: 6px;
}

/* PIN pontok */
.hcji-pin-dots {
    display: flex;
    justify-content: center;
    gap: 22px;
    margin-bottom: 32px;
}
.hcji-dot {
    display: block;
    width: 20px;
    height: 20px;
    border: 2.5px solid var(--hc-border);
    border-radius: 50%;
    background: transparent;
    transition: background .15s, border-color .15s, transform .15s;
}
.hcji-dot.filled {
    background: var(--hc-gold);
    border-color: var(--hc-gold);
    transform: scale(1.1);
}
.hcji-dot.error {
    background: var(--hc-red);
    border-color: var(--hc-red);
    animation: hcji-shake .35s ease;
}
@keyframes hcji-shake {
    0%,100% { transform: translateX(0); }
    20%,60%  { transform: translateX(-6px); }
    40%,80%  { transform: translateX(6px); }
}

/* PIN hibaüzenet */
.hcji-pin-error {
    background: #fff0f0;
    border: 1px solid #f5c6c6;
    border-radius: 10px;
    padding: 12px 18px;
    text-align: center;
    color: var(--hc-red);
    font-size: 14px;
    margin-bottom: 18px;
    font-weight: 500;
}
.hcji-lock-warning {
    text-align: center;
    color: var(--hc-red);
    font-size: 14px;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: #fff0f0;
    border-radius: 10px;
    border: 1px solid #f5c6c6;
    font-weight: 500;
}

/* PIN billentyűzet */
.hcji-pin-pad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    max-width: 320px;
    margin: 0 auto 28px;
}
.hcji-pin-key {
    aspect-ratio: 1 / 1;
    min-height: 80px;
    border: 1.5px solid var(--hc-border) !important;
    border-radius: 14px;
    background: #fff !important;
    font-size: 26px;
    font-weight: 500;
    color: var(--hc-text) !important;
    cursor: pointer;
    font-family: var(--hc-font-sans);
    transition: background .1s, transform .08s, border-color .15s, box-shadow .15s;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    box-shadow: 0 2px 6px rgba(0,0,0,.05);
}
.hcji-pin-key:hover {
    background: var(--hc-bg) !important;
    border-color: var(--hc-gold) !important;
    box-shadow: 0 4px 12px rgba(184,150,46,.15);
}
.hcji-pin-key:active {
    transform: scale(.91);
    box-shadow: none;
}
.hcji-pin-key:disabled,
.hcji-pin-key[disabled] {
    opacity: .3;
    cursor: not-allowed;
    pointer-events: none;
    box-shadow: none;
}
.hcji-pin-ok {
    background: var(--hc-gold) !important;
    border-color: var(--hc-gold) !important;
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(184,150,46,.35) !important;
}
.hcji-pin-ok:hover {
    background: var(--hc-gold-lt) !important;
    border-color: var(--hc-gold-lt) !important;
}
.hcji-pin-ok:disabled,
.hcji-pin-ok[disabled] {
    background: var(--hc-border) !important;
    border-color: var(--hc-border) !important;
    color: var(--hc-muted) !important;
    opacity: 1;
    box-shadow: none !important;
}

/* GDPR */
.hcji-gdpr-link {
    text-align: center;
    margin-top: 28px;
}
.hcji-gdpr-link a {
    color: var(--hc-muted);
    font-size: 12px;
    text-decoration: underline;
}

/* ════════════════════════════════════════════════
   DASHBOARD
   ════════════════════════════════════════════ */
.hcji-greeting {
    font-size: 20px;
    color: var(--hc-text);
    margin-bottom: 4px;
    line-height: 1.4;
}
.hcji-greeting strong {
    color: var(--hc-gold-dk);
    font-family: var(--hc-font-serif);
}
.hcji-date-display {
    font-size: 14px;
    color: var(--hc-muted);
    margin-bottom: 18px;
}

/* Idő sor */
.hcji-time-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 18px;
}
.hcji-time-block {
    flex: 1;
    text-align: center;
}
.hcji-time-label {
    font-size: 11px;
    color: var(--hc-muted);
    text-transform: uppercase;
    letter-spacing: .8px;
    margin-bottom: 4px;
}
.hcji-time-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--hc-text);
    font-variant-numeric: tabular-nums;
    letter-spacing: .5px;
    line-height: 1.2;
}
.hcji-time-divider {
    width: 1px;
    height: 44px;
    background: var(--hc-border);
    margin: 0 20px;
    flex-shrink: 0;
}

/* Mai összesítő */
.hcji-daily-total {
    text-align: center;
    padding: 10px 16px;
    background: var(--hc-bg);
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    color: var(--hc-muted);
    line-height: 1.5;
}
.hcji-daily-total #hcji-daily-value {
    font-size: 17px;
    font-weight: 600;
    color: var(--hc-text);
    margin-left: 6px;
}

/* CHECK-IN / CHECK-OUT GOMBOK */
.hcji-btn {
    width: 100%;
    padding: 19px 24px !important;
    border: none !important;
    border-radius: 12px;
    font-size: 18px !important;
    font-weight: 600;
    font-family: var(--hc-font-sans);
    cursor: pointer;
    transition: transform .1s, box-shadow .2s;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    letter-spacing: .2px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 10px;
    line-height: 1.2;
}
.hcji-btn:active {
    transform: scale(.97);
}
.hcji-btn-checkin {
    background: var(--hc-green) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(45, 122, 79, .30);
    margin-bottom: 0;
}
.hcji-btn-checkin:hover {
    box-shadow: 0 6px 20px rgba(45, 122, 79, .40);
}
.hcji-btn-checkout {
    background: var(--hc-red) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(184, 50, 50, .30);
}
.hcji-btn-checkout:hover {
    box-shadow: 0 6px 20px rgba(184, 50, 50, .40);
}

/* Visszaszámláló */
.hcji-countdown-wrap {
    margin-top: 16px;
    text-align: center;
}
.hcji-countdown-bar-bg {
    width: 100%;
    height: 5px;
    background: var(--hc-border);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 10px;
}
.hcji-countdown-bar {
    height: 100%;
    background: var(--hc-gold);
    border-radius: 3px;
    transition: width 1s linear;
    width: 100%;
}
.hcji-countdown-text {
    font-size: 13px;
    color: var(--hc-muted);
    margin-bottom: 10px;
}
.hcji-btn-stay {
    border: 1.5px solid var(--hc-border) !important;
    border-radius: 8px;
    padding: 8px 20px;
    font-size: 13px;
    color: var(--hc-muted);
    background: transparent !important;
    cursor: pointer;
    font-family: var(--hc-font-sans);
    transition: border-color .2s, color .2s;
    display: inline-flex !important;
}
.hcji-btn-stay:hover {
    border-color: var(--hc-gold) !important;
    color: var(--hc-gold);
}

/* Statisztika kártyák */
.hcji-stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 14px;
}
.hcji-stat-card {
    text-align: center;
    padding: 20px 16px;
}
.hcji-stat-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .9px;
    color: var(--hc-muted);
    margin-bottom: 8px;
    line-height: 1.4;
}
.hcji-stat-time {
    font-size: 20px;
    font-weight: 700;
    color: var(--hc-text);
    margin-bottom: 4px;
    font-variant-numeric: tabular-nums;
    line-height: 1.3;
}
.hcji-stat-salary {
    font-size: 14px;
    color: var(--hc-gold-dk);
    font-weight: 500;
}

/* Távollétek */
.hcji-absence-card {
    padding: 18px 22px;
}
.hcji-absence-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .9px;
    color: var(--hc-muted);
    margin-bottom: 12px;
}
.hcji-absence-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--hc-border);
}
.hcji-absence-item:last-child {
    border-bottom: none;
}
.hcji-absence-type-badge {
    background: var(--hc-bg);
    border: 1px solid var(--hc-border);
    border-radius: 20px;
    padding: 3px 12px;
    font-size: 12px;
    white-space: nowrap;
}
.hcji-absence-dates {
    font-size: 13px;
    color: var(--hc-muted);
}

/* Beosztás kártya */
.hcji-schedule-card {
    padding: 18px 22px;
}
.hcji-schedule-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .9px;
    color: var(--hc-muted);
    margin-bottom: 14px;
}
.hcji-sched-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--hc-border);
    gap: 12px;
}
.hcji-sched-row:last-child {
    border-bottom: none;
}
.hcji-sched-row-date {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 70px;
}
.hcji-sched-row-datefmt {
    font-size: 14px;
    font-weight: 600;
    color: var(--hc-text);
}
.hcji-sched-row-dayname {
    font-size: 11px;
    color: var(--hc-muted);
    text-transform: capitalize;
}
.hcji-sched-row-time {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}
.hcji-sched-row-shift {
    font-size: 15px;
    font-weight: 700;
    color: var(--hc-blue);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.hcji-sched-row-note {
    font-size: 11px;
    color: var(--hc-muted);
    font-style: italic;
}

/* Heti naptár (beosztás) */
.hcji-sched-week {
    margin-bottom: 18px;
}
.hcji-sched-week:last-child {
    margin-bottom: 0;
}
.hcji-sched-week-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--hc-muted);
    margin-bottom: 8px;
    font-weight: 600;
}
.hcji-sched-week-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}
.hcji-sched-day-cell {
    background: rgba(255,255,255,.06);
    border: 1px solid var(--hc-border);
    border-radius: 8px;
    padding: 7px 3px;
    text-align: center;
    transition: background .15s;
}
.hcji-sched-day-today {
    border-color: var(--hc-gold);
    background: rgba(184,150,46,.12);
}
.hcji-sched-day-off {
    background: rgba(255,255,255,.03);
}
.hcji-sched-day-has-shift {
    background: rgba(45,122,79,.14);
    border-color: rgba(45,122,79,.3);
}
.hcji-sched-day-short {
    font-size: 10px;
    font-weight: 700;
    color: var(--hc-muted);
    text-transform: uppercase;
    line-height: 1;
}
.hcji-sched-day-date {
    font-size: 10px;
    color: var(--hc-muted);
    margin: 3px 0;
    line-height: 1;
}
.hcji-sched-day-shift {
    font-size: 10px;
    font-weight: 600;
    color: var(--hc-text);
    line-height: 1.2;
    word-break: break-all;
}
.hcji-sched-day-free {
    color: #c0843a;
}
.hcji-sched-day-empty {
    color: var(--hc-border);
}

/* Havi napi bontás */
.hcji-days-card {
    padding: 18px 22px;
}
.hcji-days-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .9px;
    color: var(--hc-muted);
    margin-bottom: 12px;
}
.hcji-day-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 0;
    border-bottom: 1px solid var(--hc-border);
}
.hcji-day-item:last-child {
    border-bottom: none;
}
.hcji-day-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.hcji-day-date {
    font-size: 14px;
    font-weight: 600;
    color: var(--hc-text);
}
.hcji-day-name {
    font-size: 11px;
    color: var(--hc-muted);
    text-transform: capitalize;
}
.hcji-day-time {
    font-size: 14px;
    font-weight: 600;
    color: var(--hc-blue);
    font-variant-numeric: tabular-nums;
}

/* Megerősítő overlay */
.hcji-confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(250,247,242,.93);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    animation: hcji-fade-in .2s ease;
}
@keyframes hcji-fade-in {
    from { opacity:0; }
    to   { opacity:1; }
}
.hcji-confirm-icon {
    font-size: 64px;
    margin-bottom: 14px;
    animation: hcji-pop .35s cubic-bezier(.34,1.56,.64,1);
}
@keyframes hcji-pop {
    from { transform: scale(0); }
    to   { transform: scale(1); }
}
.hcji-confirm-text {
    font-size: 20px;
    font-weight: 600;
    color: var(--hc-text);
    font-family: var(--hc-font-serif);
}

/* ── Responsive ── */
@media (max-width: 480px) {
    #hcji-login-screen,
    #hcji-dashboard        { padding: 20px 14px 52px; }
    .hcji-stats-row        { grid-template-columns: 1fr; }
    .hcji-step-title       { font-size: 22px !important; margin-bottom: 22px !important; }
    .hcji-pin-pad          { max-width: 280px; gap: 10px; }
    .hcji-pin-key          { min-height: 70px; font-size: 22px; }
    .hcji-pin-dots         { gap: 18px; margin-bottom: 26px; }
    .hcji-dot              { width: 18px; height: 18px; }
    .hcji-time-value       { font-size: 22px; }
    .hcji-btn              { font-size: 16px !important; padding: 16px 20px !important; }
}

@media (min-width: 600px) {
    .hcji-pin-pad          { max-width: 340px; gap: 14px; }
    .hcji-pin-key          { min-height: 90px; font-size: 28px; }
    .hcji-btn              { font-size: 19px !important; padding: 21px 24px !important; }
}

@media (min-width: 768px) {
    #hcji-login-screen,
    #hcji-dashboard        { padding: 40px 52px 72px; }
    .hcji-step-title       { font-size: 30px !important; }
    .hcji-selected-name    { font-size: 24px; padding: 18px 24px; }
    .hcji-pin-pad          { max-width: 360px; gap: 16px; }
    .hcji-pin-key          { min-height: 96px; font-size: 30px; border-radius: 16px; }
    .hcji-dot              { width: 22px; height: 22px; }
    .hcji-pin-dots         { gap: 26px; margin-bottom: 36px; }
    .hcji-emp-item         { min-height: 72px; padding: 20px 24px; }
    .hcji-emp-item-name    { font-size: 18px; }
}
