/* Custom Dropdown (cd-*) for language selection */
.custom-dropdown {
  position: relative;
  display: inline-block;
  min-width: 170px;
  font-family: inherit;
  direction: rtl;
}
.custom-dropdown .cd-toggle {
  width: 100%;
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 0.55rem 1.2rem 0.55rem 2.2rem;
  font-size: 1rem;
  font-weight: 700;
  text-align: right;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: border-color .2s, background .2s;
  box-shadow: 0 2px 8px rgba(124,58,237,0.07);
  position: relative;
}
.custom-dropdown .cd-toggle:focus {
  outline: none;
  border-color: var(--accent);
}
.custom-dropdown .cd-arrow {
  border: solid var(--accent);
  border-width: 0 3px 3px 0;
  display: inline-block;
  padding: 4px;
  margin-right: 8px;
  transform: rotate(45deg);
  transition: transform .2s;
}
.custom-dropdown[aria-expanded="true"] .cd-arrow {
  transform: rotate(-135deg);
}
.custom-dropdown .cd-list {
  display: none;
  position: absolute;
  top: 110%;
  right: 0;
  min-width: 100%;
  background: var(--surface);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  box-shadow: 0 8px 32px rgba(124,58,237,0.13);
  z-index: 200;
  padding: 0.3rem 0;
  margin: 0;
  list-style: none;
  text-align: right;
}
.custom-dropdown.open .cd-list,
.custom-dropdown[aria-expanded="true"] .cd-list {
  display: block;
}
.custom-dropdown .cd-list li {
  padding: 0.6rem 1.2rem 0.6rem 2.2rem;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text);
  transition: background .18s, color .18s;
  white-space: nowrap;
}
.custom-dropdown .cd-list li[aria-selected="true"] {
  color: var(--accent);
  font-weight: 800;
  background: rgba(124,58,237,0.08);
}
.custom-dropdown .cd-list li:hover {
  background: rgba(124,58,237,0.13);
  color: var(--accent);
}
.custom-dropdown .cd-value {
  flex: 1;
  text-align: right;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}
/* End custom dropdown */
@import url('../public/assets/css/site.css');

/* Color scheme - Dark mode by default */
:root{
  --bg:#07050a;
  --bg-2:#0b0b0f;
  --card:#1a1a2e;
  --accent:#7c3aed;
  --accent-cyan:#39d9ff;
  --accent-purple:#7c3aed;
  --accent-magenta:#ff4ecf;
  --accent-mid:linear-gradient(90deg,var(--accent-cyan),var(--accent-purple),var(--accent-magenta));
  --muted:#cfcbe1;
  --text:#e6e6ee;
  --text-muted:#cfcbe1;
  --card-border:rgba(255,255,255,0.04);
  --surface:#2a2a4e;
  --file-bg:#2a2a4e;
  --file-border:rgba(124,58,237,0.25);
  --light-bg:#f8f9fc;
  --light-bg-2:#f0f2f8;
  --light-text:#0d1117;
  --light-muted:#5a6470;
  --light-card:#ffffff;
}

/* Light mode support - REMOVED - Dark mode only */

*{box-sizing:border-box}

body{
  font-family:'Inter',Segoe UI,system-ui,Arial,sans-serif;
  margin:0;
  background:var(--bg);
  color:var(--text);
  transition:background-color .3s ease,color .3s ease;
}

/* Header styling - Dark only */
header{
  background:linear-gradient(180deg,rgba(6,6,10,0.92),rgba(8,6,14,0.88));
  color:var(--text);
  padding:1rem 1.5rem;
  box-shadow:0 8px 36px rgba(2,6,23,0.65);
  position:sticky;
  top:0;
  z-index:50;
  border-bottom:1px solid rgba(124,58,237,0.06);
  transition:background-color .3s ease,color .3s ease;
}

.nav-container{
  display:flex;
  justify-content:space-between;
  align-items:center;
  max-width:1200px;
  margin:0 auto;
}

.brand{
  display:flex;
  align-items:center;
  gap:0.75rem;
  text-decoration:none;
  color:inherit;
}

.brand .logo{
  width:44px;
  height:44px;
  border-radius:8px;
  filter:drop-shadow(0 6px 18px rgba(0,0,0,0.12));
}

.nav-actions{
  display:flex;
  align-items:center;
  gap:0.75rem;
  flex-wrap:wrap;
}

.language-switcher-wrap{
  display:flex;
  align-items:center;
}

.custom-select{
  position:relative;
  display:inline-block;
}

.custom-select__button{
  background:transparent;
  border:1px solid rgba(255,255,255,0.18);
  color:#fff;
  padding:0.45rem 0.6rem;
  border-radius:8px;
  cursor:pointer;
  font-weight:600;
  display:flex;
  align-items:center;
  gap:0.4rem;
  transition:all .2s ease;
}

.custom-select__button:hover{
  border-color:rgba(124,58,237,0.5);
  background:rgba(124,58,237,0.08);
}

.custom-select__label{
  font-size:0.9rem;
  font-weight:600;
}

.custom-select__chev{
  opacity:0.7;
  transition:transform .2s ease;
}

.custom-select__button[aria-expanded="true"] .custom-select__chev{
  transform:rotate(180deg);
}

.custom-select__list{
  position:absolute;
  top:100%;
  right:0;
  list-style:none;
  margin:0.5rem 0 0;
  padding:0.4rem 0;
  background:var(--card);
  border:1px solid var(--card-border);
  border-radius:8px;
  box-shadow:0 10px 32px rgba(0,0,0,0.24);
  min-width:160px;
  display:none;
  z-index:100;
}

.custom-select__button[aria-expanded="true"]~.custom-select__list{
  display:block;
}

.custom-select__list li{
  padding:0.6rem 1rem;
  cursor:pointer;
  transition:background .2s ease;
  font-size:0.9rem;
}

.custom-select__list li:hover{
  background:rgba(124,58,237,0.12);
}

.custom-select__list li[aria-selected="true"]{
  color:var(--accent);
  font-weight:700;
}

/* Theme toggle styles removed - dark mode only */

/* Main transcriber container - premium design */
.transcriber-container{
  max-width:980px;
  margin:28px auto;
  background:linear-gradient(180deg,var(--card),var(--surface));
  border:1px solid var(--card-border);
  border-radius:16px;
  padding:28px;
  box-shadow:0 8px 32px rgba(124,58,237,0.08);
  backdrop-filter:blur(8px);
  transition:all .3s ease;
  background:linear-gradient(180deg,rgba(26,26,46,0.9),rgba(42,42,78,0.6));
  box-shadow:0 8px 32px rgba(124,58,237,0.12);
}

#transcriber-title{
  font-size:1.75rem;
  margin:0 0 1.2rem;
  background:linear-gradient(90deg,#a78bfa,#d8b4fe,#ff4ecf);
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
  font-weight:800;
  letter-spacing:-.5px;
}

/* Controls section */
.controls{
  display:flex;
  gap:0.75rem;
  flex-wrap:wrap;
  align-items:center;
  margin-bottom:1.5rem;
  padding-bottom:1.5rem;
  border-bottom:1px solid var(--card-border);
}

.controls input[type="file"],
.controls select{
  padding:0.65rem 0.8rem;
  border:1px solid var(--file-border);
  border-radius:10px;
  background:var(--file-bg);
  color:var(--text);
  font-weight:600;
  cursor:pointer;
  transition:all .2s ease;
  font-size:0.95rem;
}

.controls input[type="file"]:hover,
.controls select:hover{
  background:rgba(124,58,237,0.08);
  border-color:rgba(124,58,237,0.3);
  transform:translateY(-1px);
}

.controls input[type="file"]:focus,
.controls select:focus{
  outline:none;
  border-color:rgba(124,58,237,0.4);
  box-shadow:0 0 0 3px rgba(124,58,237,0.1);
  transform:translateY(-1px);
}

/* File input custom styling */
.controls input[type="file"]::file-selector-button{
  padding:0.4rem 0.7rem;
  background:linear-gradient(90deg,#7c3aed,#8b5cf6);
  color:#fff;
  border:none;
  border-radius:8px;
  font-weight:700;
  font-size:0.9rem;
  cursor:pointer;
  margin-right:0.6rem;
  transition:all .2s ease;
}

.controls input[type="file"]::file-selector-button:hover{
  box-shadow:0 4px 12px rgba(124,58,237,0.2);
  transform:translateY(-1px);
}

body.dark-mode .controls input[type="file"]::file-selector-button{
  background:linear-gradient(90deg,#a78bfa,#d8b4fe);
}

/* Record button - primary action */
.transcriber-record-btn{
  display:inline-flex;
  align-items:center;
  gap:0.5rem;
  padding:0.65rem 1rem;
  border-radius:10px;
  background:linear-gradient(90deg,#7c3aed,#8b5cf6);
  color:#fff;
  border:none;
  cursor:pointer;
  font-weight:700;
  font-size:0.95rem;
  box-shadow:0 10px 30px rgba(124,58,237,0.15);
  transition:all .2s ease;
}

.transcriber-record-btn:hover:not(.recording){
  transform:translateY(-2px);
  box-shadow:0 14px 40px rgba(124,58,237,0.2);
}

.transcriber-record-btn:active:not(.recording){
  transform:translateY(0);
  box-shadow:0 6px 20px rgba(124,58,237,0.15);
}

.transcriber-record-btn img{
  filter:brightness(0) invert(1);
  width:18px;
  height:18px;
}

/* Recording state - animated pulse */
.transcriber-record-btn.recording{
  background:linear-gradient(90deg,#ff4d4d,#ff6b6b);
  box-shadow:0 10px 30px rgba(255,80,80,0.2);
  animation:recordingPulse 1.5s ease-in-out infinite;
}

.transcriber-record-btn.recording:hover{
  transform:none;
}

@keyframes recordingPulse{
  0%, 100%{ box-shadow:0 10px 30px rgba(255,80,80,0.2); }
  50%{ box-shadow:0 10px 40px rgba(255,80,80,0.35); }
}

/* Transcribe button - secondary action */
#transcribeBtn{
  padding:0.65rem 1rem;
  background:linear-gradient(90deg,#7c3aed,#8b5cf6);
  color:#fff;
  border:none;
  border-radius:10px;
  font-weight:700;
  cursor:pointer;
  box-shadow:0 10px 30px rgba(124,58,237,0.15);
  transition:all .2s ease;
}

#transcribeBtn:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 40px rgba(124,58,237,0.2);
}

#transcribeBtn:active{
  transform:translateY(0);
  box-shadow:0 6px 20px rgba(124,58,237,0.15);
}

/* Output section */
.output-section{
  margin-top:1.5rem;
  padding-top:1.5rem;
  border-top:1px solid var(--card-border);
}

#outputTitle{
  font-size:1.1rem;
  margin:0 0 0.8rem;
  color:var(--text);
  font-weight:700;
  letter-spacing:-.25px;
}

/* Transcription textarea */
#transcription{
  width:100%;
  min-height:200px;
  border-radius:12px;
  border:1px solid var(--card-border);
  padding:1rem;
  background:var(--surface);
  color:var(--text);
  font-family:Monaco,Menlo,monospace;
  font-size:0.95rem;
  line-height:1.6;
  resize:vertical;
  transition:all .2s ease;
}

#transcription:focus{
  outline:none;
  border-color:rgba(124,58,237,0.3);
  background:var(--card);
  box-shadow:0 0 0 3px rgba(124,58,237,0.08);
}

/* Translation controls container */
.transcriber-container > div[style*="display:flex;gap:.6rem"]{
  display:flex !important;
  gap:0.6rem !important;
  align-items:center !important;
  justify-content:flex-start !important;
  margin-top:1.2rem !important;
  flex-wrap:wrap !important;
  padding:1rem !important;
  background:linear-gradient(135deg,rgba(124,58,237,0.08),rgba(168,85,247,0.04)) !important;
  border-radius:12px !important;
  border:1px solid rgba(124,58,237,0.15) !important;
}

body.dark-mode .transcriber-container > div[style*="display:flex;gap:.6rem"]{
  background:linear-gradient(135deg,rgba(124,58,237,0.1),rgba(168,85,247,0.05)) !important;
  border:1px solid rgba(124,58,237,0.15) !important;
}

/* Translation label */
.transcriber-container > div[style*="display:flex;gap:.6rem"] > label{
  font-weight:700 !important;
  margin-right:0.4rem !important;
  color:var(--text) !important;
}

/* Translation target select */
#translateTarget.modern-select{
  padding:0.65rem 0.8rem;
  border:1px solid rgba(124,58,237,0.15);
  border-radius:10px;
  background:var(--card);
  color:var(--text);
  font-weight:600;
  cursor:pointer;
  transition:all .2s ease;
}

#translateTarget.modern-select:hover{
  border-color:rgba(124,58,237,0.3);
  box-shadow:0 4px 12px rgba(124,58,237,0.08);
}

#translateTarget.modern-select:focus{
  outline:none;
  border-color:rgba(124,58,237,0.4);
  box-shadow:0 0 0 3px rgba(124,58,237,0.08);
}

/* Translate button - CTA */
#translateBtn.cta{
  margin-left:0.4rem !important;
  background:linear-gradient(90deg,#7c3aed,#8b5cf6) !important;
  color:#fff !important;
  border:none !important;
  padding:0.65rem 1rem !important;
  border-radius:10px !important;
  font-weight:700 !important;
  cursor:pointer !important;
  box-shadow:0 10px 30px rgba(124,58,237,0.15) !important;
  transition:all .2s ease !important;
}

#translateBtn.cta:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 40px rgba(124,58,237,0.2) !important;
}

#translateBtn.cta:active{
  transform:translateY(0);
  box-shadow:0 6px 20px rgba(124,58,237,0.15) !important;
}

/* Translate note */
#translateNote{
  opacity:0.85 !important;
  margin-left:0.5rem !important;
  color:var(--text-muted) !important;
  font-weight:600 !important;
  font-size:0.85rem !important;
}

/* Toolbar buttons */
.toolbar{
  display:flex;
  gap:0.6rem;
  justify-content:flex-start;
  flex-wrap:wrap;
  margin-top:1.2rem;
  padding-top:1rem;
  border-top:1px solid var(--card-border);
}

.toolbar button{
  padding:0.65rem 1rem;
  background:var(--card);
  border:1px solid var(--card-border);
  border-radius:10px;
  color:var(--text);
  font-weight:700;
  font-size:0.95rem;
  cursor:pointer;
  transition:all .2s ease;
}

.toolbar button:hover{
  background:linear-gradient(135deg,var(--surface),rgba(124,58,237,0.06));
  border-color:rgba(124,58,237,0.2);
  transform:translateY(-1px);
}

.toolbar button:active{
  transform:translateY(0);
  box-shadow:0 2px 6px rgba(124,58,237,0.08);
}

/* Status section */
.status{
  margin-top:1.5rem;
  padding:1rem;
  background:linear-gradient(135deg,rgba(124,58,237,0.08),rgba(168,85,247,0.04));
  border:1px solid var(--card-border);
  border-radius:12px;
  font-weight:600;
  color:var(--text);
  transition:all .3s ease;
  background:linear-gradient(135deg,rgba(124,58,237,0.1),rgba(168,85,247,0.05));
  border:1px solid rgba(124,58,237,0.15);
}

#statusText{
  color:#d8b4fe;
  font-weight:700;

/* Footer notes */
.notes{
  margin-top:1.5rem;
  padding:1rem;
  background:var(--surface);
  border-radius:12px;
  border:1px solid var(--card-border);
  font-size:0.95rem;
  color:var(--text-muted);
  line-height:1.6;
  transition:all .3s ease;
}

.notes p{
  margin:0;
}

.notes strong{
  color:#d8b4fe;
  font-weight:700;
}

/* Responsive design */
@media (max-width:820px){
  .transcriber-container{
    padding:1.5rem;
  }

  #transcriber-title{
    font-size:1.5rem;
  }

  .controls{
    flex-direction:column;
    gap:0.5rem;
  }

  .controls input[type="file"],
  .controls select,
  #transcribeBtn{
    width:100%;
  }

  .transcriber-container > div[style*="display:flex;gap:.6rem"]{
    flex-direction:column !important;
    align-items:stretch !important;
    gap:0.8rem !important;
  }

  #translateTarget.modern-select,
  #translateBtn.cta{
    width:100% !important;
    margin:0 !important;
  }

  .toolbar{
    flex-direction:column;
    align-items:stretch;
  }

  .toolbar button{
    width:100%;
  }

  #transcription{
    min-height:150px;
  }

  #outputTitle{
    font-size:1rem;
  }
}

/* Smooth transitions for theme switching */
*{
  transition:background-color .3s ease,color .3s ease,border-color .3s ease;
}

/* Ensure brand header matches global site style (gradient clipped text) */
header nav .brand h1,
header .brand h1 {
  background: var(--accent-mid);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 800;
  font-size: 1.05rem;
}
