/* ============================================================
   ORVO My Account — Owner Portal Stylesheet
   Theme: Dark, Outfit font, Teal accent (#188796)
   Based on admin.css
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400&display=swap');

/* --- Reset & Base --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
    scrollbar-gutter: stable;
    overflow-y: scroll;
    touch-action: pan-x pan-y;
}

body {
    font-family: 'Outfit', system-ui, -apple-system, sans-serif;
    background: #000000;
    color: #FFFFFF;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    opacity: 0;
    animation: pageIn 0.15s ease-out forwards;
    overflow-x: hidden;
}

body.page-exit {
    animation: pageOut 0.1s ease-in forwards;
}

a { color: #188796; text-decoration: none; }
a:hover { color: #73D1DE; }

/* --- Header --- */
.header {
    background: #0a0a0a;
    border-bottom: 1px solid #333333;
    padding: 0 24px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: #FFFFFF;
}

.logo img {
    height: 28px;
    filter: brightness(0) invert(1) opacity(0.9);
}

.logo-label {
    font-size: 14px;
    font-weight: 400;
    color: #888888;
    letter-spacing: 0.05em;
}

/* --- Hamburger Menu --- */
.menu-btn {
    background: none;
    border: 1px solid #333333;
    border-radius: 6px;
    padding: 8px 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: border-color 0.15s;
}

.menu-btn:hover {
    border-color: #666666;
}

.menu-btn span {
    display: block;
    width: 18px;
    height: 2px;
    background: #888888;
    border-radius: 1px;
    transition: background 0.15s;
}

.menu-btn:hover span {
    background: #FFFFFF;
}

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 200;
    opacity: 0;
    animation: fadeIn 0.15s ease-out forwards;
}

.menu-overlay.closing {
    animation: fadeOut 0.1s ease-in forwards;
}

.menu-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100%;
    background: #111111;
    border-left: 1px solid #333333;
    z-index: 201;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    animation: slideIn 0.2s ease-out forwards;
}

.menu-overlay.closing .menu-panel {
    animation: slideOut 0.15s ease-in forwards;
}

.menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #222222;
}

.menu-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: #FFFFFF;
}

.menu-close {
    background: none;
    border: none;
    color: #888888;
    font-size: 20px;
    cursor: pointer;
    padding: 4px;
    line-height: 1;
}

.menu-close:hover {
    color: #FFFFFF;
}

.menu-items {
    flex: 1;
    padding: 12px 0;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    color: #FFFFFF;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.1s;
    cursor: pointer;
    border: none;
    background: transparent;
    width: 100%;
    font-family: inherit;
    text-align: left;
}

.menu-item:hover {
    background: #2a2a2a;
    color: #FFFFFF;
}

.menu-item:active {
    background: #3a3a3a;
}

.menu-item.active {
    color: #188796;
}

.menu-item-icon {
    width: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #888888;
}

.menu-item:hover .menu-item-icon,
.menu-item.active .menu-item-icon {
    color: inherit;
}

.menu-divider {
    height: 1px;
    background: #222222;
    margin: 8px 0;
}

.menu-footer {
    padding: 16px 24px;
    border-top: 1px solid #222222;
}

.menu-user {
    font-size: 13px;
    color: #666666;
}

/* --- Footer --- */
.footer {
    border-top: 1px solid #222222;
    padding: 2rem 24px;
    text-align: center;
}

.footer-logo {
    width: 80px;
    filter: brightness(0) invert(1) opacity(0.3);
    margin-bottom: 1rem;
}

.footer p {
    font-size: 0.8rem;
    color: #444444;
    font-family: 'JetBrains Mono', monospace;
    margin: 0;
}

/* --- Page Layout --- */
.page {
    flex: 1;
    padding: 88px 24px 60px;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.page-title {
    font-size: 22px;
    font-weight: 700;
    color: #FFFFFF;
}

/* --- Cards --- */
.card {
    background: #171717;
    border: 1px solid #333333;
    border-radius: 10px;
    padding: 32px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 20px;
}

.card-form {
    max-width: 560px;
    margin: 0 auto;
}

.card-logo {
    display: block;
    width: 180px;
    margin: 0 auto 12px;
    filter: brightness(0) invert(1) opacity(0.9);
}

.card p.card-subtitle {
    font-size: 14px;
    color: #888888;
    text-align: center;
    margin-bottom: 28px;
    font-weight: 300;
}

/* --- Shop Cards --- */
.shop-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.shop-card {
    background: #171717;
    border: 1px solid #333333;
    border-radius: 10px;
    padding: 24px;
    transition: border-color 0.15s;
}

.shop-card:hover {
    border-color: #444444;
}

.shop-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.shop-card-name {
    font-size: 18px;
    font-weight: 600;
    color: #FFFFFF;
}

.shop-card-code {
    font-size: 13px;
    color: #888888;
    font-family: 'JetBrains Mono', monospace;
    margin-bottom: 12px;
}

.shop-card-detail {
    font-size: 14px;
    color: #AAAAAA;
    margin-bottom: 4px;
}

.shop-card-detail span {
    color: #CCCCCC;
}

/* --- Forms --- */
.field {
    margin-bottom: 20px;
}

.field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #AAAAAA;
    margin-bottom: 6px;
}

.field input,
.field select {
    width: 100%;
    background: #222222;
    color: #FFFFFF;
    border: 1px solid #444444;
    border-radius: 6px;
    padding: 12px 14px;
    font-size: 16px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
}

.field input::placeholder {
    color: #666666;
}

.field input:focus,
.field select:focus {
    border-color: #188796;
}

.error-msg {
    font-size: 13px;
    color: #B52B2B;
    text-align: center;
    margin-bottom: 12px;
    min-height: 18px;
}

/* --- Badges --- */
.badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 100px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-active {
    background: rgba(12, 171, 65, 0.15);
    color: #0CAB41;
}

.badge-inactive {
    background: rgba(181, 43, 43, 0.15);
    color: #B52B2B;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #171717;
    color: #FFFFFF;
    border: 1px solid #444444;
    border-radius: 6px;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    text-decoration: none;
}

.btn:hover {
    background: #2a2a2a;
    border-color: #666666;
    color: #FFFFFF;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-accent {
    background: #188796;
    border-color: #188796;
}

.btn-accent:hover {
    background: #1a9dae;
    border-color: #1a9dae;
}

.btn-full {
    width: 100%;
    padding: 14px;
    font-size: 16px;
}

/* --- Placeholder Pages --- */
.placeholder {
    text-align: center;
    padding: 80px 24px;
}

.placeholder-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.3;
}

.placeholder h2 {
    font-size: 20px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 8px;
}

.placeholder p {
    font-size: 14px;
    color: #666666;
}

/* --- Toast Notifications --- */
.toast-container {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    border: none;
    border-left: 4px solid;
    border-radius: 10px;
    padding: 16px 24px;
    font-size: 14px;
    font-weight: 500;
    color: #FFFFFF;
    animation: toastIn 0.3s ease-out;
    max-width: 420px;
}

.toast-icon {
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
}

.toast-success {
    background: #0a3d1a;
    border-left-color: #0CAB41;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.6), 0 0 24px rgba(12, 171, 65, 0.2);
}

.toast-success .toast-icon {
    background: rgba(12, 171, 65, 0.35);
    color: #4ADE80;
}

.toast-error {
    background: #3b1111;
    border-left-color: #B52B2B;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.6), 0 0 24px rgba(181, 43, 43, 0.2);
}

.toast-error .toast-icon {
    background: rgba(181, 43, 43, 0.35);
    color: #F87171;
}

/* --- Page Loading Bar --- */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    z-index: 9999;
    pointer-events: none;
}

.page-loader-bar {
    height: 100%;
    background: #188796;
    box-shadow: 0 0 8px rgba(24, 135, 150, 0.6);
    border-radius: 0 2px 2px 0;
    width: 0;
    animation: pageLoad 1.8s ease-in-out infinite;
}

@keyframes pageLoad {
    0%   { width: 0; margin-left: 0; }
    50%  { width: 40%; margin-left: 30%; }
    100% { width: 0; margin-left: 100%; }
}

/* --- Login --- */
.main-centered {
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 24px;
    padding-top: max(10vh, 40px);
}

.card-login {
    width: 100%;
    max-width: 400px;
    padding: 40px 36px;
}

.back-link {
    display: block;
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: #666666;
    text-decoration: none;
    transition: color 0.15s;
}

.back-link:hover {
    color: #188796;
}

.forgot-link {
    display: block;
    text-align: center;
    margin-top: 16px;
    font-size: 13px;
    color: #888888;
    text-decoration: none;
    transition: color 0.15s;
}

.forgot-link:hover {
    color: #188796;
}

/* --- Success Message --- */
.success-card {
    text-align: center;
}

.success-icon {
    width: 64px;
    height: 64px;
    background: rgba(12, 171, 65, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 32px;
    color: #0CAB41;
}

/* --- Loading --- */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
    color: #555555;
    font-size: 14px;
}

/* --- Animations --- */
@keyframes pageIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes pageOut {
    from { opacity: 1; }
    to   { opacity: 0; }
}

@keyframes toastIn {
    from { opacity: 0; transform: translateY(-12px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes toastOut {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to { opacity: 0; transform: translateY(-12px) scale(0.96); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

@keyframes slideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

@keyframes slideOut {
    from { transform: translateX(0); }
    to { transform: translateX(100%); }
}

/* --- Responsive --- */
@media (max-width: 600px) {
    .header { padding: 0 16px; }
    .logo img { height: 22px; }
    .page { padding: 76px 16px 60px; }
    .card { padding: 24px 20px; }
    .shop-grid { grid-template-columns: 1fr; }
    .toast-container { top: 72px; left: 50%; transform: translateX(-50%); right: auto; width: calc(100% - 32px); }
    .toast { max-width: 100%; }
}
