/* D:\mohabbat_pwapp.css - Professional Light Theme */
:root {
  --primary: #ffca28; /* Slightly deeper yellow/amber */
  --primary-dark: #ffb300;
  --bg-dark: #f0f2f5; /* App shell background */
  --bg-light: #ffffff;
  --text-main: #1a1a1a;
  --text-muted: #6c757d;
  --glass-bg: #ffffff;
  --glass-border: rgba(0, 0, 0, 0.08);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 15px rgba(0,0,0,0.06);
  --nav-height: 65px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  height: 100%;
  font-family: 'Poppins', sans-serif;
  color: var(--text-main);
  overflow: hidden; /* App shell handles scrolling */
  background: var(--bg-dark);
}

/* Background - Clean Light Gradient */
.animated-bg {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  z-index: -2;
}

.glass-overlay {
  display: none; /* Not needed for clean light theme */
}

/* App Shell Layout */
.app-shell {
  display: flex; flex-direction: column; height: 100%; width: 100%; max-width: 600px; margin: 0 auto; position: relative;
  box-shadow: 0 0 40px rgba(0,0,0,0.1); background: var(--bg-dark);
}

.app-header {
  height: 60px; display: flex; align-items: center; padding: 0 20px;
  background: #ffffff; border-bottom: 1px solid var(--glass-border);
  box-shadow: var(--shadow-sm); z-index: 5; position: relative;
}
.app-logo { width: 35px; height: 35px; border-radius: 50%; margin-right: 15px; box-shadow: var(--shadow-sm); }
.app-title { font-size: 18px; font-weight: 500; flex: 1; letter-spacing: 0.5px; color: var(--text-main); }
.app-title b { font-weight: 700; color: var(--primary-dark); }
.live-badge {
  font-size: 11px; font-weight: bold; color: #fff; background: #f44336;
  padding: 4px 10px; border-radius: 20px; display: flex; align-items: center; gap: 5px; box-shadow: 0 2px 5px rgba(244,67,54,0.3);
}
.live-badge .dot { width: 8px; height: 8px; background: #fff; border-radius: 50%; animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: 0.4; } }

/* Views Container */
.views-container {
  flex: 1; position: relative; overflow: hidden;
}
.view-section {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  display: flex; flex-direction: column;
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
  overflow-y: auto; overflow-x: hidden;
}
.view-section.active {
  opacity: 1; pointer-events: auto;
}
.view-header {
  padding: 25px 20px 10px;
}
.view-header h2 { font-size: 24px; font-weight: 700; margin-bottom: 5px; color: var(--text-main); }
.view-header p { font-size: 14px; color: var(--text-muted); }

/* Glass Components -> Clean Cards */
.glass-card {
  background: #ffffff; border: 1px solid var(--glass-border); box-shadow: var(--shadow-md);
  border-radius: 20px; padding: 20px; margin: 15px 20px;
}

/* UI Elements */
.input-group { display: flex; align-items: center; background: #f8f9fa; border-radius: 12px; margin-bottom: 15px; padding: 0 15px; border: 1px solid #e9ecef; transition: 0.2s; }
.input-group:focus-within { border-color: var(--primary-dark); background: #ffffff; box-shadow: 0 0 0 3px rgba(255,202,40,0.1); }
.input-group i { color: var(--primary-dark); font-size: 16px; width: 30px; }
.input-group input { flex: 1; background: transparent; border: none; padding: 15px 0; color: var(--text-main); font-family: inherit; font-size: 15px; outline: none; }
.input-group input::placeholder { color: #adb5bd; }

.primary-btn { background: var(--primary); color: #000; border: none; padding: 15px 20px; border-radius: 12px; font-weight: 600; font-size: 15px; cursor: pointer; transition: 0.2s; font-family: inherit; box-shadow: 0 4px 10px rgba(255,202,40,0.3); }
.primary-btn:active { transform: scale(0.98); box-shadow: 0 2px 5px rgba(255,202,40,0.3); }
.primary-btn.small { padding: 8px 15px; border-radius: 8px; font-size: 13px; }
.primary-btn.full-width { width: 100%; }
.secondary-btn { background: #ffffff; color: var(--text-main); border: 1px solid #ced4da; padding: 10px 20px; border-radius: 12px; font-weight: 500; cursor: pointer; font-family: inherit; box-shadow: var(--shadow-sm); transition: 0.2s; }
.secondary-btn:active { background: #f8f9fa; }

.mt-2 { margin-top: 10px; } .mt-3 { margin-top: 15px; }
.error-text { color: #dc3545; font-size: 13px; }
.success-msg { color: #198754; font-size: 14px; margin-top: 10px; text-align: center; display: none; }

/* Bottom Nav */
.bottom-nav {
  height: var(--nav-height); background: #ffffff;
  display: flex; justify-content: space-around; align-items: center;
  border-top: 1px solid var(--glass-border); padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -2px 10px rgba(0,0,0,0.02); z-index: 5; position: relative;
}
.nav-item {
  color: #000000; background: transparent; border: none; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; cursor: pointer; transition: 0.2s; font-family: inherit;
}
.nav-item i { font-size: 22px; margin-bottom: 4px; transition: 0.2s; font-weight: 900; }
.nav-item span { font-size: 11px; font-weight: 600; }
.nav-item.active { color: var(--primary-dark); }
.nav-item.active i { transform: translateY(-2px); font-size: 24px; }

/* --- 1. RADIO VIEW --- */
.radio-container {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 20px;
}
.vinyl-wrapper {
  width: 250px; height: 250px; border-radius: 50%; position: relative; margin-bottom: 40px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.15); background: transparent; display: flex; justify-content: center; align-items: center;
}
.vinyl-record {
  width: 95%; height: 95%; border-radius: 50%; object-fit: cover;
  animation: spin 8s linear infinite; animation-play-state: paused; border: 8px solid #333;
}
.vinyl-hole { position: absolute; width: 30px; height: 30px; background: #f0f2f5; border-radius: 50%; border: 1px solid rgba(0,0,0,0.1); }
.vinyl-wrapper.playing .vinyl-record { animation-play-state: running; }
@keyframes spin { 100% { transform: rotate(360deg); } }

.metadata-box { text-align: center; margin-bottom: 40px; width: 100%; }
.metadata-box h2 { font-size: 24px; font-weight: 700; margin-bottom: 5px; color: var(--text-main); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.metadata-box p { font-size: 15px; color: var(--text-muted); }

.player-controls { display: flex; align-items: center; gap: 30px; margin-bottom: 30px; }
.ctrl-btn { background: #ffffff; border: 1px solid var(--glass-border); width: 55px; height: 55px; border-radius: 50%; color: var(--text-main); font-size: 20px; cursor: pointer; display: flex; justify-content: center; align-items: center; box-shadow: var(--shadow-sm); transition: 0.2s; }
.ctrl-btn:active { background: #f8f9fa; transform: scale(0.95); }
.play-btn { width: 80px; height: 80px; background: var(--primary); color: #000; font-size: 28px; border: none; box-shadow: 0 10px 25px rgba(255,202,40,0.4); }
.play-btn:active { transform: scale(0.95); box-shadow: 0 5px 15px rgba(255,202,40,0.4); }

.volume-slider-container { width: 85%; display: flex; align-items: center; background: #ffffff; padding: 12px 25px; border-radius: 30px; box-shadow: var(--shadow-sm); border: 1px solid var(--glass-border); }
#volSlider { -webkit-appearance: none; width: 100%; height: 6px; background: #e9ecef; border-radius: 3px; outline: none; }
#volSlider::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: var(--primary-dark); cursor: pointer; box-shadow: 0 2px 5px rgba(0,0,0,0.2); }

/* --- 2. PODCAST VIEW --- */
.podcast-list { padding: 0 20px 80px; }
.pod-card { display: flex; background: #ffffff; border: 1px solid var(--glass-border); border-radius: 16px; padding: 12px; margin-bottom: 15px; align-items: center; gap: 15px; cursor: pointer; box-shadow: var(--shadow-sm); transition: 0.2s; }
.pod-card:active { transform: scale(0.98); background: #f8f9fa; }
.pod-img { width: 70px; height: 70px; border-radius: 12px; object-fit: cover; background: #e9ecef; box-shadow: var(--shadow-sm); }
.pod-info { flex: 1; overflow: hidden; }
.pod-title { font-size: 15px; font-weight: 600; margin-bottom: 5px; color: var(--text-main); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pod-date { font-size: 13px; color: var(--text-muted); }
.pod-play { width: 40px; height: 40px; border-radius: 50%; background: #fff8e1; display: flex; justify-content: center; align-items: center; font-size: 14px; color: var(--primary-dark); border: 1px solid #ffecb3; }

/* Podcast Mini Player (Bottom Sheet) */
.mini-player { position: absolute; bottom: 0; left: 0; right: 0; background: #ffffff; border-top: 1px solid var(--glass-border); border-top-left-radius: 30px; border-top-right-radius: 30px; padding: 20px 20px 40px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; height: 80vh; max-height: 80vh; transform: translateY(100%); transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: 20; box-shadow: 0 -10px 40px rgba(0,0,0,0.1); overflow-y: auto; }
.mini-player.active { transform: translateY(0); }
.mp-title { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-bottom: 5px; }
.mp-prog { height: 3px; background: rgba(0,0,0,0.05); border-radius: 2px; }
.mp-prog-bar { height: 100%; background: var(--primary); width: 0%; border-radius: 2px; }
.small-play { width: 40px; height: 40px; background: var(--primary); color: #000; border: none; font-size: 14px; cursor: pointer; transition: 0.2s; }
.small-close { width: 30px; height: 30px; background: transparent; border: none; color: var(--text-muted); font-size: 16px; margin-left: -5px; cursor: pointer; }

/* --- 3. CHAT ROOM VIEW --- */
.chat-wrapper { display: flex; flex-direction: column; height: 100%; position: relative; }
.chat-tabs { display: flex; padding: 15px 20px 5px; gap: 15px; }
.c-tab { flex: 1; background: #ffffff; border: 1px solid var(--glass-border); color: var(--text-muted); padding: 12px; border-radius: 12px; font-weight: 600; cursor: pointer; transition: 0.2s; box-shadow: var(--shadow-sm); font-size: 14px; }
.c-tab.active { background: #fff8e1; color: var(--primary-dark); border-color: #ffecb3; }

.chat-content { flex: 1; display: none; flex-direction: column; overflow: hidden; }
.chat-content.active { display: flex; }

.c-messages { flex: 1; padding: 15px 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 15px; }
.c-input-area { padding: 15px 20px; background: #ffffff; border-top: 1px solid var(--glass-border); display: flex; align-items: center; gap: 12px; box-shadow: 0 -2px 10px rgba(0,0,0,0.02); }
.c-icon-btn { background: #f8f9fa; border: 1px solid var(--glass-border); width: 45px; height: 45px; border-radius: 50%; color: var(--text-muted); cursor: pointer; font-size: 18px; transition: 0.2s; }
.c-icon-btn:active { background: #e9ecef; }
.c-input { flex: 1; background: #f8f9fa; border: 1px solid var(--glass-border); border-radius: 25px; padding: 12px 18px; color: var(--text-main); outline: none; font-size: 15px; transition: 0.2s; }
.c-input:focus { background: #ffffff; border-color: var(--primary-dark); box-shadow: 0 0 0 3px rgba(255,202,40,0.1); }
.c-send-btn { background: var(--primary); color: #000; border: none; width: 45px; height: 45px; border-radius: 50%; display: flex; justify-content: center; align-items: center; cursor: pointer; font-size: 16px; box-shadow: 0 4px 10px rgba(255,202,40,0.3); transition: 0.2s; }
.c-send-btn:active { transform: scale(0.95); }
.c-send-btn:disabled { opacity: 0.5; cursor: not-allowed; box-shadow: none; }

.c-msg { display: flex; max-width: 85%; }
.c-msg.mine { align-self: flex-end; flex-direction: row-reverse; }
.c-msg.theirs { align-self: flex-start; }
.c-msg-av { width: 35px; height: 35px; border-radius: 50%; object-fit: cover; margin: 0 10px; cursor: pointer; background: #e9ecef; box-shadow: var(--shadow-sm); }
.c-msg-body { display: flex; flex-direction: column; }
.c-msg.mine .c-msg-body { align-items: flex-end; }
.c-msg.theirs .c-msg-body { align-items: flex-start; }
.c-msg-name { font-size: 12px; color: var(--primary-dark); margin-bottom: 4px; font-weight: 600; padding: 0 4px; }
.c-msg-text { padding: 12px 16px; border-radius: 18px; font-size: 14px; line-height: 1.5; word-wrap: break-word; box-shadow: var(--shadow-sm); }
.c-msg.mine .c-msg-text { background: var(--primary); color: #000; border-top-right-radius: 4px; }
.c-msg.theirs .c-msg-text { background: #ffffff; color: var(--text-main); border: 1px solid var(--glass-border); border-top-left-radius: 4px; }
.c-msg-img { max-width: 220px; border-radius: 16px; margin-top: 5px; border: 1px solid var(--glass-border); cursor: pointer; box-shadow: var(--shadow-sm); }
.c-msg-time { font-size: 11px; color: var(--text-muted); margin-top: 5px; padding: 0 4px; }
.c-date-sep { text-align: center; margin: 20px 0 10px; }
.c-date-sep span { background: #ffffff; padding: 6px 16px; border-radius: 20px; font-size: 12px; color: var(--text-muted); border: 1px solid var(--glass-border); box-shadow: var(--shadow-sm); font-weight: 500; }

/* Inbox */
.inbox-list { padding: 15px 20px; overflow-y: auto; flex: 1; }
.inbox-item { display: flex; padding: 15px; border-radius: 16px; background: #ffffff; border: 1px solid var(--glass-border); margin-bottom: 12px; align-items: center; cursor: pointer; box-shadow: var(--shadow-sm); transition: 0.2s; }
.inbox-item:active { transform: scale(0.98); background: #f8f9fa; }
.inbox-item .c-msg-av { width: 50px; height: 50px; margin-right: 15px; margin-left: 0; }
.inbox-info { flex: 1; overflow: hidden; }
.inbox-name { font-weight: 600; font-size: 15px; margin-bottom: 4px; color: var(--text-main); }
.inbox-last { font-size: 13px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.empty-text { text-align: center; color: var(--text-muted); font-size: 15px; padding: 40px 20px; }

/* Private Room */
.private-room { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: var(--bg-dark); display: flex; flex-direction: column; transform: translateX(100%); transition: transform 0.3s ease; z-index: 10; }
.private-room.active { transform: translateX(0); }
.pr-header { display: flex; align-items: center; padding: 15px 20px; background: #ffffff; border-bottom: 1px solid var(--glass-border); gap: 15px; box-shadow: var(--shadow-sm); }
.pr-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; box-shadow: var(--shadow-sm); }
.pr-name { flex: 1; font-weight: 600; font-size: 16px; color: var(--text-main); }
#prBackBtn { color: var(--text-main); background: transparent; border: none; box-shadow: none; font-size: 20px; }

/* Modal & Setup */
.modal-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(5px); z-index: 1000; display: none; justify-content: center; align-items: center; padding: 20px; }
.modal-content { width: 100%; max-width: 360px; text-align: center; background: #ffffff; border-radius: 24px; padding: 30px 25px; box-shadow: 0 10px 40px rgba(0,0,0,0.2); }
.modal-content h3 { margin-bottom: 25px; color: var(--text-main); font-size: 22px; }
.avatar-upload { display: flex; flex-direction: column; align-items: center; margin-bottom: 25px; }
.avatar-upload img { width: 100px; height: 100px; border-radius: 50%; border: 3px solid var(--primary); object-fit: cover; margin-bottom: 15px; box-shadow: var(--shadow-md); }
.c-input.full-width { width: 100%; text-align: center; font-size: 16px; padding: 15px; }

/* Request Tab specific */
.req-form { display: flex; flex-direction: column; }
.rj-status-card { background: #ffffff; border-radius: 20px; padding: 25px 20px; margin: 0 20px 20px; border: 1px solid var(--glass-border); text-align: center; box-shadow: var(--shadow-md); }
.rj-status-card h3 { font-size: 18px; margin-bottom: 15px; color: var(--text-main); }

/* Image Viewer */
.image-viewer { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.95); z-index: 10000; display: none; justify-content: center; align-items: center; padding: 20px; }
.close-viewer { position: absolute; top: 20px; right: 20px; background: none; border: none; color: #fff; font-size: 30px; cursor: pointer; padding: 10px; }
.image-viewer img { max-width: 100%; max-height: 80%; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.5); }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #ced4da; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: #adb5bd; }

.scrolling-text-container { animation: scroll-left 15s linear infinite; display: inline-block; padding-left: 100%; } @keyframes scroll-left {
  0% { transform: translateX(10%); }
  100% { transform: translateX(-100%); }
}

