:root {
  --bg: #0e2238;
  --bg-deep: #08111d;
  --surface: rgba(10, 24, 40, 0.72);
  --surface-soft: rgba(255, 255, 255, 0.08);
  --surface-strong: rgba(255, 255, 255, 0.14);
  --text: #f6fbff;
  --muted: #b8c8d8;
  --line: rgba(255, 255, 255, 0.12);
  --accent: #ff8b5e;
  --accent-strong: #ff6a3d;
  --accent-soft: rgba(255, 139, 94, 0.18);
  --success: #7be0b5;
  --shadow: 0 30px 80px rgba(1, 10, 20, 0.35);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: 'Kanit', sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(33, 92, 173, 0.7), transparent 34%),
    radial-gradient(circle at bottom right, rgba(255, 130, 84, 0.3), transparent 22%),
    linear-gradient(135deg, #102742 0%, #0a1523 52%, #07111b 100%);
}

a,
a:hover {
  color: inherit;
}

.app-shell {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
}

.bg-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(12px);
  opacity: 0.85;
  pointer-events: none;
}

.orb-one {
  top: -120px;
  right: -80px;
  width: 340px;
  height: 340px;
  background: radial-gradient(circle, rgba(71, 165, 255, 0.42) 0%, rgba(71, 165, 255, 0) 68%);
}

.orb-two {
  left: -80px;
  bottom: -120px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(255, 133, 80, 0.26) 0%, rgba(255, 133, 80, 0) 70%);
}

.top-nav {
  padding-top: 1.5rem;
  padding-bottom: 1rem;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.brand-text {
  font-size: 1.02rem;
}

.nav-link {
  color: rgba(255, 255, 255, 0.82) !important;
  font-weight: 400;
}

.nav-link:hover,
.nav-item.active .nav-link {
  color: #fff !important;
}

.nav-pill {
  padding: 0.65rem 1rem !important;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.nav-divider {
  width: 1px;
  height: 24px;
  margin: 0 0.7rem;
  background: rgba(255, 255, 255, 0.2);
}

.hero-section {
  position: relative;
  z-index: 1;
  padding-top: 3rem;
  padding-bottom: 4.5rem;
}

.hero-stack {
  display: grid;
  gap: 2.5rem;
  justify-items: center;
}

.hero-intro {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.hero-upload {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
}

.eyebrow,
.panel-badge,
.preview-kicker,
.share-result__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  width: fit-content;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid rgba(255, 139, 94, 0.22);
  color: #ffd5c8;
  font-size: 0.88rem;
  letter-spacing: 0.03em;
}

.hero-title {
  margin-top: 1rem;
  margin-bottom: 1.5rem;
  font-size: clamp(2.5rem, 5vw, 4.4rem);
  line-height: 1.05;
  font-weight: 500;
}

.hero-copy {
  max-width: 580px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 1.7rem;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.8;
}

.hero-points {
  display: grid;
  gap: 0.85rem;
  margin-bottom: 2rem;
  justify-content: center;
}

.hero-point {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  justify-content: center;
  color: #eef7ff;
  font-size: 1rem;
}

.hero-point i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #8ad8ff;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.stat-chip {
  min-width: 130px;
  padding: 1rem 1.1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
}

.stat-chip strong {
  display: block;
  margin-bottom: 0.1rem;
  font-size: 1.3rem;
  font-weight: 600;
}

.stat-chip span {
  color: var(--muted);
  font-size: 0.92rem;
}

.upload-panel {
  padding: 2rem;
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(10, 24, 40, 0.9) 0%, rgba(9, 20, 34, 0.82) 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.upload-panel__header {
  text-align: center;
}

.upload-panel__header h2 {
  margin-top: 0.9rem;
  margin-bottom: 0.55rem;
  font-weight: 600;
}

.upload-panel__header p {
  margin-bottom: 1.6rem;
  color: var(--muted);
  line-height: 1.7;
}

.upload-form input[type="file"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.upload-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  min-height: 260px;
  padding: 1.8rem;
  border: 1.5px dashed rgba(139, 195, 255, 0.34);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.03)),
    rgba(255, 255, 255, 0.02);
  text-align: center;
  cursor: pointer;
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease;
}

.upload-dropzone:hover,
.upload-dropzone:focus {
  transform: translateY(-2px);
  border-color: rgba(255, 158, 120, 0.6);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04)),
    rgba(255, 255, 255, 0.03);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.upload-dropzone.is-uploading {
  border-color: rgba(123, 224, 181, 0.7);
  background:
    linear-gradient(180deg, rgba(123, 224, 181, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(255, 255, 255, 0.03);
}

.upload-dropzone__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(255, 141, 95, 0.25), rgba(94, 180, 255, 0.25));
  color: #fff;
  font-size: 1.8rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.upload-dropzone__title {
  font-size: 1.35rem;
  font-weight: 600;
}

.upload-dropzone__meta {
  max-width: 100%;
  color: var(--muted);
  font-size: 0.98rem;
  word-break: break-word;
}

.upload-dropzone__hint {
  margin-top: 0.35rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #eff8ff;
  font-size: 0.9rem;
}

.upload-guides {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
  justify-content: center;
}

.upload-guides > div {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 0.9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.92rem;
}

.upload-guides i {
  color: #8ad8ff;
}

.upload-result-area {
  margin-top: 1.4rem;
}

.upload-preview-card,
.share-result {
  padding: 1rem;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(10px);
}

.upload-preview-card {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 1rem;
  align-items: center;
}

.upload-preview-media,
.share-result__preview {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
}

.upload-preview-media img,
.share-result__preview img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.upload-preview-media {
  min-height: 170px;
}

.upload-preview-copy h3,
.share-result__copy h3 {
  margin-top: 0.75rem;
  margin-bottom: 0.45rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.upload-preview-copy p,
.share-result__copy p {
  margin-bottom: 0.9rem;
  color: var(--muted);
  line-height: 1.65;
}

.upload-progress-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 84px;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  background: rgba(123, 224, 181, 0.12);
  color: var(--success);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.share-result {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 1.1rem;
}

.share-result__preview {
  min-height: 180px;
}

.share-result__preview-link {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 180px;
  padding: 0.9rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02)),
    rgba(9, 18, 30, 0.55);
}

.share-result__preview-link img {
  object-fit: contain;
}

.share-result__preview-note {
  position: absolute;
  right: 0.8rem;
  bottom: 0.8rem;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  background: rgba(7, 17, 27, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 500;
}

.share-result__label {
  display: block;
  margin-bottom: 0.5rem;
  color: #eef8ff;
  font-size: 0.94rem;
  font-weight: 500;
}

.share-result__url-card {
  display: block;
  margin-bottom: 0.85rem;
  padding: 0.95rem 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.share-result__url-card:hover {
  transform: translateY(-1px);
  border-color: rgba(138, 216, 255, 0.45);
  background: rgba(255, 255, 255, 0.1);
}

.share-result__url-text {
  display: block;
  color: #dff2ff;
  font-size: 0.95rem;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.share-result__input {
  display: none;
}

.share-result__button,
.share-result__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  padding: 0 1rem;
  border: none;
  border-radius: 16px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, opacity 0.2s ease, background 0.2s ease;
}

.share-result__button {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
}

.share-result__button:hover,
.share-result__link:hover {
  transform: translateY(-1px);
  color: #fff;
}

.share-result__link {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #eff8ff;
}

.share-result__actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.swal2-popup.app-toast {
  border-radius: 18px !important;
  background: linear-gradient(180deg, rgba(10, 24, 40, 0.96) 0%, rgba(9, 20, 34, 0.92) 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 20px 50px rgba(1, 10, 20, 0.38) !important;
  color: var(--text) !important;
  backdrop-filter: blur(18px);
}

.swal2-popup.app-toast .swal2-title {
  color: #fff !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
}

.swal2-popup.app-toast .swal2-html-container {
  margin-top: 0.2rem !important;
  color: var(--muted) !important;
  font-size: 0.9rem !important;
}

.swal2-popup.app-toast .swal2-success-ring {
  border-color: rgba(123, 224, 181, 0.28) !important;
}

.swal2-popup.app-toast .swal2-success-line-tip,
.swal2-popup.app-toast .swal2-success-line-long {
  background-color: var(--success) !important;
}

.swal2-popup.app-toast .swal2-timer-progress-bar {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong)) !important;
}

@media (max-width: 991.98px) {
  .top-nav {
    padding-top: 1rem;
  }

  .hero-section {
    padding-top: 1rem;
  }

  .upload-panel {
    padding: 1.5rem;
  }
}

@media (max-width: 767.98px) {
  .hero-title {
    font-size: 2.35rem;
  }

  .upload-panel {
    border-radius: 24px;
  }

  .upload-preview-card,
  .share-result {
    grid-template-columns: 1fr;
  }

  .share-result__field,
  .share-result__actions {
    flex-direction: column;
  }

  .share-result__button,
  .share-result__link {
    min-height: 48px;
    width: 100%;
  }
}
