.voice-recorder-app,
.voice-recorder-app * { box-sizing: border-box; }

.voice-recorder-app {
  --vr-deep: #0a2016;
  --vr-panel: #103124;
  --vr-panel-2: #173f30;
  --vr-line: rgba(127, 215, 174, .22);
  --vr-mint: #7fd7ae;
  --vr-amber: #f5b841;
  --vr-amber-soft: #ffd57e;
  --vr-paper: #fbf5e8;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  color: #e8f0eb;
  background: var(--vr-deep);
  font-family: Inter, var(--body);
}

.voice-recorder-app button,
.voice-recorder-app input,
.voice-recorder-app select { font: inherit; }

.vr-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(240px, .65fr);
  align-items: end;
  gap: clamp(26px, 5vw, 70px);
  padding: clamp(28px, 5vw, 58px);
  background: radial-gradient(650px 340px at 100% 0, rgba(127, 215, 174, .14), transparent 65%), radial-gradient(rgba(245, 184, 65, .075) 1px, transparent 1.5px);
  background-size: auto, 20px 20px;
  border-bottom: 1px solid rgba(245, 184, 65, .22);
}

.vr-eyebrow { margin: 0 0 8px !important; color: var(--vr-mint) !important; text-transform: uppercase; letter-spacing: .17em; font-size: 9px !important; font-weight: 850; }
.vr-intro h1 { max-width: 760px; margin: 0; color: #fff8e7 !important; font-family: var(--display) !important; font-size: clamp(32px, 5vw, 58px) !important; font-weight: 650 !important; line-height: 1.02 !important; letter-spacing: -.045em !important; }
.vr-intro > div:first-child > p:last-child { max-width: 720px; margin: 17px 0 0 !important; color: #b7cbbf !important; font-size: clamp(14px, 1.8vw, 17px) !important; line-height: 1.6 !important; }
.vr-badges { display: grid; gap: 8px; }
.vr-badges span { display: flex; align-items: center; gap: 10px; padding: 12px 0; color: #c1d1c7; border-bottom: 1px solid rgba(255, 255, 255, .11); font-size: 11px; font-weight: 750; }
.vr-badges b { width: 8px; height: 8px; background: var(--vr-mint); border-radius: 50%; box-shadow: 0 0 0 4px rgba(127, 215, 174, .09); }

.voice-recorder-app .container { width: 100%; max-width: none; margin: 0; padding: clamp(16px, 3.5vw, 38px); background: linear-gradient(135deg, #102d21, #153d2d); }
.vr-start-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); gap: 14px; margin-bottom: 14px; }

.voice-recorder-app .drop-area,
.voice-recorder-app .record-container { min-width: 0; min-height: 190px; border: 1px solid var(--vr-line); border-radius: 16px; }
.voice-recorder-app .drop-area { position: relative; display: grid; grid-template-columns: auto 1fr; align-content: center; gap: 5px 16px; padding: clamp(22px, 4vw, 38px); color: #e9f2ec; background: rgba(6, 27, 18, .6); border-style: dashed; cursor: pointer; transition: .2s ease; }
.voice-recorder-app .drop-area:hover,
.voice-recorder-app .drop-area:focus-visible,
.voice-recorder-app .drop-area.dragover { background: rgba(127, 215, 174, .08); border-color: var(--vr-mint); outline: none; }
.voice-recorder-app .drop-area input { display: none; }
.voice-recorder-app .drop-area strong { display: block; color: #fff8e7; font-size: clamp(17px, 2vw, 21px); }
.voice-recorder-app .drop-area p { margin: 5px 0 0 !important; color: #9eb5a7 !important; font-size: 12px !important; }
.voice-recorder-app .drop-area p span { color: var(--vr-amber-soft); text-decoration: underline; text-underline-offset: 3px; }
.voice-recorder-app .drop-area small { grid-column: 2; color: #789184; font-size: 9px; line-height: 1.5; }
.vr-upload-icon { display: grid; place-items: center; grid-row: 1 / span 2; width: 48px; height: 48px; color: #27331d; background: linear-gradient(145deg, var(--vr-amber-soft), var(--vr-amber)); border-radius: 14px; font-size: 23px; font-weight: 850; }

.voice-recorder-app .record-container { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); align-content: center; justify-items: center; align-items: center; gap: 13px; margin: 0; padding: clamp(20px, 3vw, 30px); background: rgba(6, 27, 18, .6); text-align: center; }
.vr-record-copy span { display: block; margin-bottom: 4px; color: #8fa99a; text-transform: uppercase; letter-spacing: .12em; font-size: 8px; font-weight: 850; }
.vr-record-copy strong { color: #fff8e7; font-size: clamp(16px, 2vw, 20px); }
.voice-recorder-app .record-btn { display: grid; place-items: center; width: 76px; height: 76px; padding: 0; overflow: hidden; background: radial-gradient(circle, #fff7e7 0 43%, #f5b841 45% 58%, #5a321f 60%); border: 1px solid rgba(245, 184, 65, .55); border-radius: 50%; cursor: pointer; box-shadow: 0 15px 35px -20px rgba(245, 184, 65, .9); transition: transform .2s ease, box-shadow .2s ease; }
.voice-recorder-app .record-btn:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 18px 38px -18px rgba(245, 184, 65, .95); }
.voice-recorder-app .record-btn img { display: block; width: 48px; height: 48px; object-fit: contain; }
.voice-recorder-app .record-msg { grid-column: 1 / -1; min-height: 0; margin: 0 !important; color: #ffb09d; text-align: center; font-size: 11px; opacity: 0; transition: opacity .25s; }
.voice-recorder-app .record-msg.show { opacity: 1; }
.voice-recorder-app .recording { animation: vr-pulse 1s ease-in-out infinite; }
@keyframes vr-pulse { 50% { opacity: .5; transform: scale(.93); } }
.voice-recorder-app .noise-cancel { grid-column: 1 / -1; margin: 0; }
.voice-recorder-app .noise-cancel label { display: flex; align-items: center; justify-content: center; gap: 9px; color: #c2d2c8; cursor: pointer; font-size: 11px; font-weight: 750; }
.voice-recorder-app .noise-cancel input { width: 17px; height: 17px; accent-color: var(--vr-mint); }

.vr-editor { padding: clamp(18px, 3vw, 28px); background: rgba(6, 27, 18, .72); border: 1px solid rgba(245, 184, 65, .2); border-radius: 17px; }
.vr-editor-heading { display: flex; align-items: end; justify-content: space-between; gap: 22px; margin-bottom: 16px; }
.vr-editor-heading h2 { margin: 0; color: #fff8e7 !important; font-size: clamp(18px, 2.6vw, 26px) !important; font-weight: 760 !important; line-height: 1.2 !important; }
.vr-editor-heading > p { max-width: 260px; margin: 0 !important; color: #8fa99a !important; font-size: 10px !important; text-align: right; }

.voice-recorder-app .waveform-wrapper { position: relative; width: 100%; height: clamp(150px, 23vw, 230px); margin: 0 0 16px; overflow: hidden; background: #f8f3e7; border: 1px solid #c7bfae; border-radius: 0; cursor: pointer; touch-action: none; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .55); }
.voice-recorder-app #waveform { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(90deg, transparent 0 49px, rgba(23, 55, 42, .055) 50px); }
.voice-recorder-app .waveform-empty {
  position: absolute;
  inset: 0;
  z-index: 8;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 7px;
  padding: 24px;
  color: #496255;
  background:
    radial-gradient(circle at 50% 42%, rgba(127, 215, 174, .12), transparent 30%),
    repeating-linear-gradient(90deg, transparent 0 49px, rgba(23, 55, 42, .055) 50px),
    #f8f3e7;
  text-align: center;
  pointer-events: none;
}
.voice-recorder-app .waveform-empty[hidden] { display: none; }
.voice-recorder-app .waveform-empty-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  margin-bottom: 3px;
  color: #173b2b;
  background: linear-gradient(145deg, #ffd57e, #f5b841);
  border-radius: 14px;
  box-shadow: 0 12px 25px -17px rgba(74, 54, 10, .8);
  font-size: 21px;
  font-weight: 850;
}
.voice-recorder-app .waveform-empty strong { color: #244536; font-size: clamp(15px, 2vw, 19px); }
.voice-recorder-app .waveform-empty p { width: auto; margin: 0 !important; color: #71877b !important; font-size: clamp(11px, 1.35vw, 13px) !important; line-height: 1.5 !important; }
.voice-recorder-app .selection { position: absolute; top: 0; height: 100%; background: rgba(127, 215, 174, .28); border-inline: 1px solid rgba(23, 107, 80, .45); cursor: grab; touch-action: none; }
.voice-recorder-app .marker-edge { position: absolute; top: -6px; z-index: 12; width: 28px; height: 28px; transform: translateX(-50%); background: url("marker.png") center / contain no-repeat; cursor: ew-resize; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .25)); }
.voice-recorder-app #playhead { position: absolute; top: 0; width: 2px; height: 100%; background: #b77912; cursor: ew-resize; touch-action: none; box-shadow: 0 0 0 1px rgba(255, 255, 255, .6); }
.voice-recorder-app .hidden { display: none; }

.voice-recorder-app #downloadMessage { display: none; position: absolute; inset: 50% auto auto 50%; z-index: 20; width: min(88%, 330px); padding: 17px 20px; transform: translate(-50%, -50%); color: #fff8e7; background: #123b2a; border: 1px solid rgba(245, 184, 65, .55); border-radius: 12px; box-shadow: 0 20px 45px -22px rgba(0, 0, 0, .8); text-align: center; font-size: 12px; font-weight: 750; line-height: 1.6; }

.voice-recorder-app .bottom-controls { display: grid; grid-template-columns: auto minmax(260px, .75fr) minmax(340px, 1fr); align-items: end; gap: 14px; position: static; width: 100%; padding: 0; }
.voice-recorder-app .play-pause-btn { display: grid; place-items: center; gap: 5px; min-width: 76px; min-height: 66px; padding: 8px 12px; color: #e7f0ea; background: rgba(255, 255, 255, .045); border: 1px solid rgba(255, 255, 255, .13); border-radius: 11px; cursor: pointer; font-size: 9px; font-weight: 800; }
.voice-recorder-app .play-pause-btn img { width: 25px; height: 25px; object-fit: contain; }
.voice-recorder-app .play-pause-btn img[src$="pause.png"] {
  filter: brightness(0) saturate(100%) invert(84%) sepia(54%) saturate(764%) hue-rotate(342deg) brightness(103%) contrast(101%);
}
.voice-recorder-app .time-selectors { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.voice-recorder-app .time-control { display: grid; gap: 6px; }
.voice-recorder-app .time-control label,
.format-field > span { color: #91aa9c; text-transform: uppercase; letter-spacing: .11em; font-size: 8px; font-weight: 850; }
.voice-recorder-app .time-box { display: grid; grid-template-columns: 34px minmax(0, 1fr) 34px; overflow: hidden; background: #0a251a; border: 1px solid rgba(127, 215, 174, .25); border-radius: 9px; }
.voice-recorder-app .time-box button { color: var(--vr-amber-soft); background: transparent; border: 0; cursor: pointer; font-size: 18px; }
.voice-recorder-app .time-box button:hover { background: rgba(245, 184, 65, .09); }
.voice-recorder-app .time-box input { width: 100%; min-width: 0; padding: 9px 4px; color: #e7f0ea; background: transparent; border: 0; border-inline: 1px solid rgba(127, 215, 174, .16); outline: none; text-align: center; font-size: 11px; font-weight: 800; }
.export-controls { display: grid; grid-template-columns: auto minmax(94px, .55fr) auto; align-items: end; gap: 8px; }
.voice-recorder-app .crop-btn,
.voice-recorder-app .download-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 42px; padding: 9px 13px; border-radius: 9px; cursor: pointer; font-size: 10px; font-weight: 850; white-space: nowrap; }
.voice-recorder-app .crop-btn { color: #dce8e1; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .14); }
.voice-recorder-app .download-btn { color: #302b17; background: linear-gradient(145deg, var(--vr-amber-soft), var(--vr-amber)); border: 1px solid #dda62e; }
.voice-recorder-app :is(.crop-btn, .download-btn):hover { transform: translateY(-1px); filter: brightness(1.04); }
.voice-recorder-app .disabled { opacity: .38; pointer-events: none; }
.format-field { display: grid; gap: 6px; }
.voice-recorder-app #formatSelect { width: 100%; min-height: 42px; padding: 8px 28px 8px 10px; color: #e8f0eb; background: #0a251a; border: 1px solid rgba(127, 215, 174, .25); border-radius: 9px; outline: none; font-size: 10px; font-weight: 800; }
.voice-recorder-app #formatSelect:focus { border-color: var(--vr-amber); box-shadow: 0 0 0 3px rgba(245, 184, 65, .12); }

@media (max-width: 900px) {
  .vr-intro { grid-template-columns: 1fr; }
  .vr-badges { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .vr-start-grid { grid-template-columns: 1fr; }
  .voice-recorder-app .bottom-controls { grid-template-columns: auto 1fr; }
  .export-controls { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .vr-intro { padding: 26px 18px; }
  .vr-badges { grid-template-columns: 1fr; gap: 0; }
  .voice-recorder-app .container { padding: 12px; }
  .voice-recorder-app .drop-area { grid-template-columns: 1fr; text-align: center; }
  .vr-upload-icon { grid-row: auto; margin: 0 auto 8px; }
  .voice-recorder-app .drop-area small { grid-column: auto; }
  .vr-editor { padding: 14px; }
  .vr-editor-heading { display: block; }
  .vr-editor-heading > p { margin-top: 7px !important; text-align: left; }
  .voice-recorder-app .waveform-wrapper { height: 150px; }
  .voice-recorder-app .bottom-controls { grid-template-columns: 1fr; }
  .voice-recorder-app .play-pause-btn { width: 100%; min-height: 48px; grid-template-columns: auto auto; }
  .export-controls { grid-column: auto; grid-template-columns: 1fr 1fr; }
  .export-controls .download-btn { grid-column: 1 / -1; }
}

@media (max-width: 390px) {
  .voice-recorder-app .time-selectors,
  .export-controls { grid-template-columns: 1fr; }
  .export-controls .download-btn { grid-column: auto; }
}
