/* ── Restaurant Profile (rp- prefix) ─────────────────────────────────── */
/* Dark theme matching OrderManagement design language */

.rp-page {
    min-height: 100vh;
    background: #0F1412;
    color: #E8E8E8;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    padding-bottom: 2rem;
}

/* ── Header ──────────────────────────────────────────────────────── */
.rp-header {
    position: sticky;
    top: 0;
    z-index: 200;
    background: #0F1412;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    border-bottom: 1px solid #2E2E2E;
}
.rp-title {
    font-size: 24px;
    font-weight: 700;
    color: #FFFFFF;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.rp-title i { color: #2DD4BF; }

/* ── Cards ───────────────────────────────────────────────────────── */
.rp-card {
    background: #1A1D1C;
    border-radius: 20px;
    padding: 24px;
    margin: 16px 1.25rem;
    box-shadow: 0px 6px 20px rgba(0,0,0,0.3);
}
.rp-card-title {
    font-size: 16px;
    font-weight: 600;
    color: #FFFFFF;
    margin: 0 0 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.rp-card-title i { color: #2DD4BF; }

/* ── Profile Header ───────────────────────────────────────────────── */
.rp-profile-header {
    background: #1A1D1C;
    border-radius: 20px;
    padding: 32px 24px;
    margin: 16px 1.25rem;
    box-shadow: 0px 6px 20px rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}
.rp-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    background: #252927;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #2DD4BF;
    flex-shrink: 0;
}
.rp-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* ── Avatar Upload Wrapper ────────────────────────────────────────── */
.rp-avatar-wrapper {
    position: relative;
    cursor: pointer;
    flex-shrink: 0;
}
.rp-avatar-wrapper:hover .rp-avatar-overlay {
    opacity: 1;
}
.rp-avatar-overlay {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}
.rp-avatar-overlay i {
    color: #FFFFFF;
    font-size: 22px;
}
.rp-avatar-uploading {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
}
.rp-profile-info {
    flex: 1;
    min-width: 200px;
}
.rp-profile-name {
    font-size: 22px;
    font-weight: 700;
    color: #FFFFFF;
    margin: 0 0 4px;
}
.rp-profile-slug {
    font-size: 13px;
    color: #2DD4BF;
    margin: 0 0 4px;
}
.rp-profile-type {
    font-size: 12px;
    color: #9CA3AF;
    margin: 0;
}

/* ── Form Grid ───────────────────────────────────────────────────── */
.rp-form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.rp-form-group {
    margin-bottom: 16px;
}
.rp-form-group.full-width {
    grid-column: 1 / -1;
}
.rp-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #9CA3AF;
    margin-bottom: 6px;
}
.rp-input {
    width: 100%;
    padding: 10px 12px;
    background: #0F1412;
    border: 1px solid #2E2E2E;
    border-radius: 10px;
    color: #E8E8E8;
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.rp-input:focus { border-color: #2DD4BF; box-shadow: 0 0 0 3px rgba(45,212,191,0.08); }
.rp-textarea {
    width: 100%;
    padding: 10px 12px;
    background: #0F1412;
    border: 1px solid #2E2E2E;
    border-radius: 10px;
    color: #E8E8E8;
    font-size: 14px;
    outline: none;
    box-sizing: border-box;
    resize: vertical;
    min-height: 80px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.rp-textarea:focus { border-color: #2DD4BF; box-shadow: 0 0 0 3px rgba(45,212,191,0.08); }

/* ── Buttons ─────────────────────────────────────────────────────── */
.rp-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 20px;
    transition: all 0.2s ease;
    white-space: nowrap;
}
.rp-btn-primary {
    background: linear-gradient(135deg, #2DD4BF, #22C55E);
    color: #0F1412;
    box-shadow: 0 2px 8px rgba(45,212,191,0.2);
}
.rp-btn-primary:hover { background: linear-gradient(135deg, #14B8A6, #16A34A); }
.rp-btn-ghost { background: transparent; border: 1px solid #2E2E2E; color: #9CA3AF; }
.rp-btn-ghost:hover { border-color: #2DD4BF; color: #2DD4BF; }
.rp-btn-danger { background: rgba(239,68,68,0.15); color: #EF4444; border: 1px solid rgba(239,68,68,0.3); }
.rp-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ── Business Hours Table ─────────────────────────────────────────── */
.rp-hours-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}
.rp-hours-table th {
    text-align: left;
    padding: 8px 12px;
    font-size: 12px;
    font-weight: 600;
    color: #9CA3AF;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #2E2E2E;
}
.rp-hours-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #1F2A27;
    font-size: 14px;
    vertical-align: middle;
}
.rp-hours-day {
    font-weight: 600;
    color: #E8E8E8;
}
.rp-hours-time {
    display: flex;
    align-items: center;
    gap: 8px;
}
.rp-hours-time .rp-input {
    width: auto;
    min-width: 100px;
    padding: 6px 10px;
    font-size: 13px;
}
.rp-hours-closed {
    color: #6B7280;
    font-style: italic;
}
.rp-hours-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.rp-checkbox {
    width: 18px;
    height: 18px;
    accent-color: #2DD4BF;
    cursor: pointer;
}

/* ── Slug / Menu Link ─────────────────────────────────────────────── */
.rp-slug-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 13px;
    color: #9CA3AF;
}
.rp-slug-preview a {
    color: #2DD4BF;
    text-decoration: none;
    word-break: break-all;
}
.rp-slug-preview a:hover { text-decoration: underline; }

/* ── Loading & Empty ──────────────────────────────────────────────── */
.rp-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #6B7280;
}
.rp-spinner {
    width: 36px; height: 36px;
    border: 3px solid #2E2E2E;
    border-top-color: #2DD4BF;
    border-radius: 50%;
    animation: rp-spin 0.8s linear infinite;
    margin-bottom: 12px;
}
@keyframes rp-spin { to { transform: rotate(360deg); } }

/* ── Toast ─────────────────────────────────────────────────────────── */
.rp-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    z-index: 4000;
    animation: rp-slide-in 0.3s ease;
}
.rp-toast-success { background: rgba(45,212,191,0.15); color: #2DD4BF; border: 1px solid rgba(45,212,191,0.3); }
.rp-toast-error { background: rgba(239,68,68,0.15); color: #EF4444; border: 1px solid rgba(239,68,68,0.3); }
@keyframes rp-slide-in { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* ── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .rp-profile-header { flex-direction: column; text-align: center; padding: 24px 16px; }
    .rp-card { margin: 12px 1rem; padding: 16px; }
    .rp-form-grid { grid-template-columns: 1fr; }
}