﻿@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;600;700&family=Space+Grotesk:wght@400;600;700&display=swap');

:root {
  --bg: #0a0f1f;
  --panel: rgba(12, 18, 38, 0.85);
  --panel-2: rgba(20, 28, 52, 0.85);
  --ink: #e8f0ff;
  --muted: #9fb0d1;
  --accent: #2ef2ff;
  --accent-2: #8b5cf6;
  --line: rgba(126, 160, 255, 0.2);
  --glow: 0 0 20px rgba(46, 242, 255, 0.25);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background:
    radial-gradient(900px 600px at 10% -10%, rgba(46, 242, 255, 0.25) 0%, transparent 60%),
    radial-gradient(700px 500px at 90% 0%, rgba(139, 92, 246, 0.25) 0%, transparent 55%),
    linear-gradient(180deg, #05070f 0%, #0a1020 40%, #0a0f1f 100%);
  color: var(--ink);
  font-family: "Space Grotesk", system-ui, sans-serif;
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: transparent;
  padding: 10px 0;
}

.nav {
  max-width: 620px;
  margin: 0 auto;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(8, 12, 24, 0.75);
  border: 1px solid var(--line);
  border-radius: 10px;
}

.brand {
  font-family: "Orbitron", sans-serif;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 18px;
  color: var(--accent);
  text-shadow: var(--glow);
}

.nav-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: nowrap;
  justify-content: space-between;
  width: 100%;
}

.nav select,
.nav button {
  height: 36px;
}

.nav-user {
  color: var(--muted);
  font-size: 13px;
}

.hero {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 24px 12px;
  display: grid;
  gap: 8px;
}

.title {
  font-family: "Orbitron", sans-serif;
  font-size: 30px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.subtitle {
  color: var(--muted);
  max-width: 680px;
}

main {
  max-width: 1200px;
  margin: 0 auto 56px;
  padding: 0 24px 48px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 20px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  animation: fadeUp 0.5s ease both;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 0%, rgba(46, 242, 255, 0.08) 40%, transparent 80%);
  pointer-events: none;
  opacity: 0.7;
}

.card h2 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 600;
  color: var(--accent);
  text-shadow: var(--glow);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  display: block;
  margin-bottom: 6px;
}

input, select, textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(126, 160, 255, 0.35);
  background: rgba(10, 16, 32, 0.8);
  color: var(--ink);
  font-size: 14px;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(46, 242, 255, 0.15);
}

.actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

button {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #08101f;
  border: none;
  padding: 10px 16px;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--glow);
  transition: transform 0.12s ease, box-shadow 0.2s ease, background 0.2s ease;
}

button.secondary {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  box-shadow: none;
  transition: transform 0.12s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

button:hover {
  background: linear-gradient(135deg, #1a9cff, #3cff9a, #ffe45e);
  box-shadow: 0 0 25px rgba(60, 255, 154, 0.25);
}

button.secondary:hover {
  border-color: rgba(60, 255, 154, 0.6);
  box-shadow: 0 0 18px rgba(26, 156, 255, 0.25);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.15), rgba(60, 255, 154, 0.15), rgba(255, 228, 94, 0.15));
}

button:active {
  transform: scale(0.98);
}

.results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.result-box {
  padding: 12px;
  border: 1px dashed rgba(46, 242, 255, 0.4);
  border-radius: 12px;
  background: rgba(8, 12, 24, 0.7);
}

.result-box .value {
  font-size: 20px;
  font-weight: 700;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

th, td {
  padding: 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.muted {
  color: var(--muted);
  font-size: 12px;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 20;
}

.modal.open {
  display: flex;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(6, 10, 18, 0.7);
  backdrop-filter: blur(6px);
}

.modal-card {
  position: relative;
  width: min(760px, 96vw);
  background: rgba(14, 22, 44, 0.75);
  border: 1px solid rgba(46, 242, 255, 0.35);
  border-radius: 20px;
  padding: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
  z-index: 1;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.modal-title {
  font-family: "Orbitron", sans-serif;
  letter-spacing: 0.08em;
}

.modal-close {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 20px;
}

.modal-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(10, 16, 32, 0.8);
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  font-weight: 600;
}

.tab-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: var(--glow);
}

.tab {
  display: none;
}

.tab.active {
  display: block;
}

.status {
  margin-top: 10px;
  color: var(--muted);
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(12, 22, 42, 0.9);
  border: 1px solid rgba(60, 255, 154, 0.35);
  color: var(--ink);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 30;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 720px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
  }
}

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 10, 20, 0.42);
  backdrop-filter: blur(6px);
  opacity: 1;
  visibility: visible;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.page-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-modal {
  width: min(560px, 92vw);
  border-radius: 16px;
  border: 1px solid rgba(46, 242, 255, 0.38);
  background: rgba(12, 20, 40, 0.78);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.5), 0 0 30px rgba(46, 242, 255, 0.18);
  backdrop-filter: blur(14px);
  padding: 26px 22px;
  text-align: center;
}

.loader-title {
  font-family: "Orbitron", sans-serif;
  font-size: clamp(22px, 4vw, 34px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #d6e8ff;
  text-shadow: 0 0 16px rgba(46, 242, 255, 0.24);
  margin-bottom: 14px;
}

.loader-status-wrap {
  border-top: 1px solid rgba(126, 160, 255, 0.25);
  margin-top: 12px;
  padding-top: 14px;
  min-height: 42px;
  display: grid;
  place-items: center;
}

.loader-status {
  font-size: 14px;
  letter-spacing: 0.05em;
  color: #9fe4d0;
  animation: statusPulse 1.2s ease-in-out infinite;
}

@keyframes statusPulse {
  0% { opacity: 0.45; transform: translateY(6px); }
  50% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0.45; transform: translateY(-6px); }
}


.teaser-card {
  display: grid;
  gap: 14px;
}

.teaser-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(60, 255, 154, 0.35);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.18), rgba(60, 255, 154, 0.16));
  color: #c6fbe3;
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.topbar { position: sticky; top: 0; z-index: 20; padding: 10px 0; backdrop-filter: blur(10px); }
.nav {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(8, 12, 24, 0.75);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.brand {
  flex: 0 0 auto;
  min-width: max-content;
  font-family: "Orbitron", sans-serif;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 18px;
  color: var(--accent);
  text-shadow: var(--glow);
}
.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: nowrap;
  min-width: 0;
}
.nav select,
.nav button,
.nav a.nav-conversion-btn {
  width: auto;
  min-width: 36px;
  flex: 0 0 auto;
  height: 36px;
}
.nav-user {
  max-width: 220px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
@media (max-width: 900px) {
  .nav { flex-wrap: wrap; }
  .nav-actions { width: 100%; justify-content: space-between; flex-wrap: wrap; }
  .nav-user { max-width: 100%; flex-basis: 100%; order: 10; }
}

/* Navbar and control polish */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 10px 0;
  backdrop-filter: blur(10px);
}

.nav {
  width: min(1200px, calc(100% - 32px));
  margin: 0 auto;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(8, 12, 24, 0.82);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.brand {
  flex: 0 0 auto;
  min-width: max-content;
}

.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: nowrap;
  min-width: 0;
}

.nav-user {
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  padding-right: 38px;
  background-image: linear-gradient(45deg, transparent 50%, rgba(232, 240, 255, 0.72) 50%), linear-gradient(135deg, rgba(232, 240, 255, 0.72) 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.nav select,
.nav button,
.nav a.nav-conversion-btn {
  width: auto;
  flex: 0 0 auto;
  height: 36px;
}

.nav a.nav-conversion-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(126, 160, 255, 0.35);
  background: rgba(10, 16, 32, 0.8);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.12s ease, background 0.2s ease;
}

.nav a.nav-conversion-btn:hover {
  border-color: rgba(60, 255, 154, 0.6);
  box-shadow: 0 0 14px rgba(26, 156, 255, 0.25);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.15), rgba(60, 255, 154, 0.15), rgba(255, 228, 94, 0.15));
}

.nav-conversion-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(46, 242, 255, 0.12);
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

#imageFile {
  padding: 8px;
}

#imageFile::file-selector-button {
  margin-right: 12px;
  border: 1px solid rgba(46, 242, 255, 0.45);
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.2), rgba(60, 255, 154, 0.18));
  color: var(--ink);
  padding: 8px 12px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

#imageFile::file-selector-button:hover {
  border-color: rgba(60, 255, 154, 0.75);
  box-shadow: 0 0 14px rgba(26, 156, 255, 0.25);
  filter: brightness(1.05);
}

.toggle-field {
  display: flex;
  align-items: center;
}

.toggle-control {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0;
  cursor: pointer;
}

.toggle-control input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.toggle-track {
  position: relative;
  width: 52px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(126, 160, 255, 0.35);
  background: rgba(10, 16, 32, 0.8);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.toggle-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, #dff8ff, #9fb0d1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease;
}

.toggle-control input:checked + .toggle-track {
  border-color: rgba(60, 255, 154, 0.65);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.32), rgba(60, 255, 154, 0.28));
  box-shadow: 0 0 16px rgba(46, 242, 255, 0.18);
}

.toggle-control input:checked + .toggle-track::after {
  transform: translateX(22px);
}

#conversionSubmit {
  min-width: 190px;
  justify-content: center;
}

#conversionDownload,
.conversion-download-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(46, 242, 255, 0.45);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.18), rgba(60, 255, 154, 0.16), rgba(255, 228, 94, 0.14));
  color: #dff8ff;
  text-decoration: none;
  font-weight: 700;
  font-size: 12px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
  transition: transform 0.12s ease, box-shadow 0.2s ease, border-color 0.2s ease, filter 0.2s ease;
}

#conversionDownload::before,
.conversion-download-link::before {
  content: "?";
  font-size: 13px;
  font-weight: 700;
}

#conversionDownload:hover,
.conversion-download-link:hover {
  border-color: rgba(60, 255, 154, 0.75);
  box-shadow: 0 0 14px rgba(26, 156, 255, 0.35), 0 8px 20px rgba(0, 0, 0, 0.35);
  filter: brightness(1.08);
}

#conversionDownload:active,
.conversion-download-link:active {
  transform: scale(0.98);
}

#conversionSection progress {
  width: 100%;
  height: 12px;
  border: 1px solid rgba(126, 160, 255, 0.35);
  border-radius: 999px;
  background: rgba(8, 12, 24, 0.75);
  overflow: hidden;
  appearance: none;
}

#conversionSection progress::-webkit-progress-bar {
  background: rgba(8, 12, 24, 0.75);
  border-radius: 999px;
}

#conversionSection progress::-webkit-progress-value {
  background: linear-gradient(90deg, #1a9cff, #2ef2ff, #3cff9a);
  border-radius: 999px;
  box-shadow: 0 0 16px rgba(46, 242, 255, 0.35);
  transition: width 0.25s ease;
}

#conversionSection progress::-moz-progress-bar {
  background: linear-gradient(90deg, #1a9cff, #2ef2ff, #3cff9a);
  border-radius: 999px;
  box-shadow: 0 0 16px rgba(46, 242, 255, 0.35);
}

@media (max-width: 900px) {
  .nav {
    flex-wrap: wrap;
  }

  .nav-actions {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .nav-user {
    max-width: 100%;
    flex-basis: 100%;
    order: 10;
  }
}


/* Final navbar/select/toggle cleanup */
.nav {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}

.brand {
  margin: 0;
  min-width: 0;
}

.nav-actions {
  margin-left: 0 !important;
  min-width: 0;
  width: auto !important;
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: nowrap;
}

.nav-user {
  max-width: 110px;
}

select,
.nav select,
#language,
#displayCurrency,
#baseCurrency {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  padding-right: 42px !important;
  background-color: rgba(10, 16, 32, 0.92) !important;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(232, 240, 255, 0.82) 50%),
    linear-gradient(135deg, rgba(232, 240, 255, 0.82) 50%, transparent 50%) !important;
  background-position:
    calc(100% - 18px) calc(50% - 3px),
    calc(100% - 12px) calc(50% - 3px) !important;
  background-size: 6px 6px, 6px 6px !important;
  background-repeat: no-repeat !important;
}

select::-ms-expand {
  display: none;
}

.toggle-field {
  align-self: end;
}

.toggle-control {
  width: 100%;
  min-height: 48px;
}

.toggle-track {
  flex: 0 0 52px;
  overflow: hidden;
}

.toggle-track::after {
  width: 20px;
  height: 20px;
  top: 4px;
  left: 4px;
}

.toggle-control input:checked + .toggle-track::after {
  transform: translateX(22px);
}

@media (max-width: 900px) {
  .nav {
    grid-template-columns: 1fr;
  }

  .nav-actions {
    width: 100% !important;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .nav-user {
    max-width: 100%;
    flex-basis: 100%;
    order: 10;
  }
}


/* Final cleanup 2 */
.teaser-card {
  display: none !important;
}

.nav {
  grid-template-columns: minmax(180px, max-content) minmax(0, 1fr) !important;
}

.brand {
  font-size: clamp(15px, 1.1vw, 18px);
  letter-spacing: 0.1em;
  padding-right: 10px;
}

#language,
#displayCurrency {
  min-width: 72px;
}

.nav-actions {
  overflow: hidden;
}

input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}


.subscription-card {
  display: grid;
  gap: 18px;
}

.subscription-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.subscription-status {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  min-width: 180px;
  border-radius: 14px;
  border: 1px solid rgba(46, 242, 255, 0.22);
  background: linear-gradient(135deg, rgba(10, 16, 32, 0.94), rgba(21, 33, 62, 0.84));
}

.subscription-status-label {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.subscription-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.subscription-tier {
  position: relative;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid rgba(126, 160, 255, 0.2);
  background: rgba(8, 12, 24, 0.55);
}

.subscription-tier.is-current {
  border-color: rgba(46, 242, 255, 0.48);
  box-shadow: 0 0 0 1px rgba(46, 242, 255, 0.12), inset 0 0 40px rgba(46, 242, 255, 0.04);
}

.subscription-tier-pro {
  background: linear-gradient(180deg, rgba(16, 28, 54, 0.88), rgba(9, 16, 34, 0.92));
}

.subscription-tier-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.subscription-tier h3 {
  margin: 0;
  font-size: 18px;
}

.subscription-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(126, 160, 255, 0.26);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.subscription-chip-pro {
  border-color: rgba(60, 255, 154, 0.38);
  color: #c6fbe3;
  background: rgba(60, 255, 154, 0.08);
}

.subscription-list {
  margin: 14px 0 0;
  padding-left: 18px;
  color: var(--ink);
  display: grid;
  gap: 8px;
}

.subscription-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

@media (max-width: 900px) {
  .subscription-head {
    flex-direction: column;
  }

  .subscription-status {
    min-width: 100%;
  }
}


.subscription-modal-card {
  width: min(980px, 96vw);
  max-height: 88vh;
  overflow: auto;
}

#subscriptionModal .subscription-card {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
  animation: none;
}

#subscriptionModal .subscription-card::after {
  display: none;
}


/* Dynamic navbar sizing */
.topbar {
  display: flex;
  justify-content: center;
}

.nav {
  width: fit-content;
  max-width: calc(100% - 32px);
  grid-template-columns: auto auto !important;
  justify-content: center;
}

.nav-actions {
  flex: 0 1 auto;
  width: auto !important;
  max-width: 100%;
}

@media (max-width: 900px) {
  .topbar {
    display: block;
  }

  .nav {
    width: calc(100% - 32px);
    grid-template-columns: 1fr !important;
  }

  .nav-actions {
    width: 100% !important;
  }
}


/* Navbar clipping fix */
.nav-actions {
  overflow: visible !important;
}

#navAuthBtn,
#navLogoutBtn,
 #navManageAccountBtn,
#navSubscriptionLink {
  white-space: nowrap;
}


.welcome-modal-card {
  width: min(640px, 94vw);
  display: grid;
  gap: 16px;
  text-align: center;
}

.welcome-badge {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(46, 242, 255, 0.35);
  background: rgba(46, 242, 255, 0.08);
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.welcome-text {
  font-size: 14px;
  max-width: 520px;
  margin: 0 auto;
}

.welcome-actions,
.welcome-oauth {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.welcome-divider {
  position: relative;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 11px;
}

.welcome-divider::before,
.welcome-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: calc(50% - 28px);
  height: 1px;
  background: var(--line);
}

.welcome-divider::before { left: 0; }
.welcome-divider::after { right: 0; }

.oauth-btn {
  min-width: 240px;
}

.welcome-note {
  text-align: center;
}


/* Hero and card layout refinements */
.hero {
  text-align: center;
  justify-items: center;
}

.subtitle {
  text-align: center;
}

main {
  grid-template-columns: repeat(2, minmax(320px, 380px));
  justify-content: center;
}

main > .card[style*="grid-column: 1 / -1"] {
  width: 100%;
}

/* Custom file picker */
.file-picker {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 6px;
  border-radius: 12px;
  border: 1px solid rgba(126, 160, 255, 0.35);
  background: rgba(10, 16, 32, 0.84);
}

.file-picker input[type="file"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.file-picker-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(46, 242, 255, 0.45);
  background: linear-gradient(135deg, rgba(26, 156, 255, 0.2), rgba(60, 255, 154, 0.18));
  color: var(--ink);
  font-weight: 700;
  cursor: pointer;
  margin-bottom: 0;
}

.file-picker-name {
  display: none;
  width: 100%;
  padding: 0 10px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-picker.has-file {
  padding: 0 12px;
}

.file-picker.has-file .file-picker-btn {
  display: none;
}

.file-picker.has-file .file-picker-name {
  display: block;
}

@media (max-width: 900px) {
  main {
    grid-template-columns: minmax(280px, 1fr);
  }
}


.conversion-preview {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 16px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(126, 160, 255, 0.24);
  border-radius: 14px;
  background: rgba(8, 12, 24, 0.55);
  align-items: stretch;
}

.conversion-preview-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  border-radius: 12px;
  border: 1px solid rgba(46, 242, 255, 0.2);
  background: rgba(6, 10, 20, 0.72);
  overflow: hidden;
}

.conversion-preview-frame img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 220px;
  object-fit: contain;
}

.conversion-preview-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  min-width: 0;
  gap: 10px;
}

.conversion-preview-name {
  width: 100%;
  font-weight: 700;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.35;
  word-break: break-word;
}

.conversion-preview-info {
  width: 100%;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.conversion-preview-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  width: auto;
  white-space: nowrap;
  position: relative;
  z-index: 1;
  pointer-events: auto;
}

@media (max-width: 700px) {
  .conversion-preview {
    grid-template-columns: 1fr;
  }

  .conversion-preview-frame {
    min-height: 180px;
  }

  .conversion-preview-remove {
    width: 100%;
  }
}


.subscription-state-badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(126, 160, 255, 0.28);
  background: rgba(14, 22, 42, 0.82);
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.subscription-status-meta {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  max-width: 30ch;
}

.subscription-status.is-pro {
  border-color: rgba(60, 255, 154, 0.35);
  box-shadow: 0 0 0 1px rgba(60, 255, 154, 0.08), inset 0 0 22px rgba(60, 255, 154, 0.04);
}

.subscription-status.is-pro .subscription-state-badge {
  border-color: rgba(60, 255, 154, 0.45);
  color: #c6fbe3;
  background: rgba(10, 40, 30, 0.78);
}

.subscription-status.is-warning {
  border-color: rgba(255, 196, 80, 0.38);
  box-shadow: 0 0 0 1px rgba(255, 196, 80, 0.08), inset 0 0 22px rgba(255, 196, 80, 0.04);
}

.subscription-status.is-warning .subscription-state-badge {
  border-color: rgba(255, 196, 80, 0.48);
  color: #ffe7b0;
  background: rgba(60, 38, 10, 0.8);
}

.subscription-status.is-canceled {
  border-color: rgba(255, 120, 120, 0.35);
  box-shadow: 0 0 0 1px rgba(255, 120, 120, 0.08), inset 0 0 22px rgba(255, 120, 120, 0.04);
}

.subscription-status.is-canceled .subscription-state-badge {
  border-color: rgba(255, 120, 120, 0.45);
  color: #ffd1d1;
  background: rgba(56, 18, 24, 0.82);
}


.social-strip {
  width: min(1200px, calc(100% - 32px));
  margin: 10px auto 0;
  display: flex;
  justify-content: flex-start;
  padding: 0 0 4px;
}

.social-card {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(126, 160, 255, 0.24);
  background: rgba(8, 14, 28, 0.72);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}

.social-title {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.social-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(46, 242, 255, 0.28);
  background: rgba(12, 20, 38, 0.85);
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.12s ease;
}

.social-link:hover {
  border-color: rgba(60, 255, 154, 0.62);
  box-shadow: 0 0 16px rgba(26, 156, 255, 0.22);
}

.social-link:active {
  transform: scale(0.98);
}

.oauth-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.oauth-btn::before {
  content: "G";
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: conic-gradient(from 220deg, #4285f4 0 25%, #34a853 25% 50%, #fbbc05 50% 75%, #ea4335 75% 100%);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

.oauth-btn-label {
  display: inline-flex;
  align-items: center;
}

#conversionDownload::before,
.conversion-download-link::before {
  content: "?";
  font-size: 13px;
  font-weight: 700;
}

@media (max-width: 900px) {
  .social-strip {
    justify-content: center;
  }

  .social-card {
    width: 100%;
  }
}


.social-link {
  gap: 8px;
}

.social-link-icon {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  color: var(--accent);
  flex: 0 0 18px;
}

.social-link-icon svg {
  width: 18px;
  height: 18px;
  display: block;
}


.site-footer {
  margin: 32px 0 20px;
  padding: 0 16px 24px;
}

.site-footer-inner {
  width: min(1200px, 100%);
  margin: 0 auto;
  padding: 18px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(64, 232, 255, 0.18);
  border-radius: 18px;
  background: rgba(10, 18, 36, 0.82);
}

.site-footer-brand {
  font-family: "Orbitron", sans-serif;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.site-footer-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.site-footer-links a:hover {
  color: var(--accent);
}

.legal-main {
  width: min(1200px, calc(100% - 32px));
  margin: 24px auto 0;
}

.legal-card {
  display: block;
}

.legal-nav {
  width: min(1200px, calc(100% - 32px));
}

.legal-nav-actions {
  margin-left: auto;
}

.legal-header {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.9fr);
  gap: 24px;
  align-items: start;
}

.legal-eyebrow {
  margin-bottom: 8px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
}

.legal-intro {
  max-width: 70ch;
}

.legal-page-nav {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid rgba(64, 232, 255, 0.18);
  border-radius: 16px;
  background: rgba(12, 22, 40, 0.72);
}

.legal-page-nav a {
  color: var(--ink);
  text-decoration: none;
}

.legal-page-nav a:hover {
  color: var(--accent);
}

.legal-sections {
  margin-top: 28px;
  display: grid;
  gap: 22px;
}

.legal-section {
  padding: 20px;
  border: 1px solid rgba(64, 232, 255, 0.14);
  border-radius: 16px;
  background: rgba(10, 18, 36, 0.58);
}

.legal-section h2 {
  margin: 0 0 10px;
}

.legal-section p {
  margin: 0 0 10px;
  color: var(--ink);
  line-height: 1.6;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

@media (max-width: 900px) {
  .site-footer-inner,
  .legal-header {
    grid-template-columns: 1fr;
    display: grid;
  }

  .site-footer-inner {
    justify-content: start;
  }
}

.legal-return-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid rgba(64, 232, 255, 0.28);
  background: linear-gradient(135deg, rgba(20, 36, 68, 0.92), rgba(12, 22, 40, 0.92));
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.12s ease;
}

.legal-return-link:hover {
  border-color: rgba(60, 255, 154, 0.6);
  box-shadow: 0 0 16px rgba(26, 156, 255, 0.2);
}

.legal-return-link:active {
  transform: scale(0.98);
}

.legal-card {
  padding: 28px;
}

.legal-layout {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.legal-sidebar {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 18px;
}

.legal-header {
  display: block;
}

.legal-intro {
  max-width: 40ch;
}

.legal-page-nav {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(64, 232, 255, 0.22);
  border-radius: 18px;
  background: rgba(12, 22, 40, 0.88);
}

.legal-page-nav a {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.legal-page-nav a:hover {
  color: var(--accent);
  background: rgba(20, 44, 74, 0.74);
}

.legal-sections {
  margin-top: 0;
}

@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .legal-sidebar {
    position: static;
  }
}

main.legal-main {
  display: block !important;
  max-width: 1200px !important;
  width: min(1200px, calc(100% - 32px)) !important;
  margin: 24px auto 0 !important;
  padding: 0 24px 48px !important;
}

main.legal-main > .legal-card {
  width: 100% !important;
  max-width: none !important;
  overflow: visible !important;
}

main.legal-main .legal-layout {
  display: grid !important;
  grid-template-columns: 320px minmax(420px, 1fr) !important;
  gap: 28px !important;
  align-items: start !important;
}

main.legal-main .legal-sections {
  margin-top: 0 !important;
  min-width: 0 !important;
}

@media (max-width: 900px) {
  main.legal-main .legal-layout {
    grid-template-columns: 1fr !important;
  }
}

.legal-footer-inner {
  width: min(420px, calc(100% - 32px)) !important;
  justify-content: center !important;
}

.legal-footer-inner .site-footer-brand {
  width: 100%;
  text-align: center;
}


.cookie-banner {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 35;
  width: min(520px, calc(100vw - 32px));
}

.cookie-banner[hidden] {
  display: none !important;
}

.cookie-banner-card {
  display: grid;
  gap: 18px;
  padding: 18px 20px;
  border-radius: 20px;
  border: 1px solid rgba(46, 242, 255, 0.3);
  background:
    linear-gradient(180deg, rgba(14, 22, 44, 0.96), rgba(10, 16, 32, 0.96)),
    radial-gradient(circle at top right, rgba(46, 242, 255, 0.12), transparent 42%);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.38), 0 0 0 1px rgba(46, 242, 255, 0.08);
  backdrop-filter: blur(14px);
}

.cookie-banner-copy {
  display: grid;
  gap: 8px;
}

.cookie-banner-title {
  font-family: "Orbitron", sans-serif;
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.cookie-banner-text {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.cookie-banner-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.cookie-banner-link {
  margin-right: auto;
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.cookie-banner-link:hover {
  text-decoration: underline;
}

.cookie-banner-actions button {
  min-width: 110px;
}

@media (max-width: 640px) {
  .cookie-banner {
    right: 12px;
    left: 12px;
    bottom: 12px;
    width: auto;
  }

  .cookie-banner-card {
    padding: 16px;
  }

  .cookie-banner-actions {
    justify-content: stretch;
  }

  .cookie-banner-link {
    width: 100%;
    margin-right: 0;
  }

  .cookie-banner-actions button {
    flex: 1 1 calc(50% - 6px);
  }
}

.subscription-price-box {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(46, 242, 255, 0.22);
  background: rgba(10, 18, 34, 0.6);
}

.subscription-price-label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.subscription-price-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.subscription-price-value {
  font-size: 30px;
  line-height: 1;
  color: var(--accent);
  text-shadow: var(--glow);
}

.subscription-price-period {
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}

.subscription-price-note {
  margin-top: 8px;
}

.legal-nav {
  width: min(1200px, calc(100% - 32px)) !important;
  max-width: none !important;
  grid-template-columns: 1fr auto 1fr !important;
}

.legal-brand {
  justify-self: center;
}

.legal-nav-actions {
  justify-self: end;
  margin-left: 0 !important;
}

main.legal-main {
  margin: 40px auto 0 !important;
}

main.legal-main .legal-sidebar {
  top: 112px !important;
}

