* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #f7f8ff;
  --card: #ffffff;
  --soft: #fcfbff;
  --line: #ececff;
  --line2: #d9d2ff;
  --text: #161b33;
  --muted: #7f8799;
  --muted2: #9aa1b2;
  --primary: #6958ff;
  --primary2: #836dff;
  --shadow: 0 18px 35px rgba(99, 91, 255, 0.12);
}

body {
  font-family: "Inter", sans-serif;
  background: var(--bg);
  color: var(--text);
  padding: 28px;
}

.container {
  max-width: 1220px;
  margin: 0 auto;
}

.main-card {
  padding-bottom: 10px;
}

.hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 22px;
}

.hero-left {
  flex: 1;
}

.title-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.icon-box {
  width: 100px;
  height: 100px;
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff, #f5f3ff);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 18px 40px rgba(99, 91, 255, 0.14);
  color: var(--primary);
  flex-shrink: 0;
}

.icon-box i {
  font-size: 56px;
}

h1 {
  font-size: 44px;
  line-height: 1;
  letter-spacing: -1.8px;
  font-weight: 800;
  margin-bottom: 0px !important;
}

.features {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.feature {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 15px;
  font-size: 13px;
  font-weight: 600;
  color: #5d6478;
}

.feature i {
  font-size: 13px;
  border: 7px solid #fff;
  border-radius: 50%;
  background: #fff;
}

.tool {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 24px;
  padding: 20px;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.toolbar h2 {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.4px;
}

.toolbar p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}

.toolbar-left {
  min-width: 240px;
}

.toolbar-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  border: none;
  height: 46px;
  padding: 0 16px;
  border-radius: 12px;
  background: linear-gradient(180deg, #7a68ff, #6958ff);
  color: white;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 12px 25px rgba(99, 91, 255, 0.2);
  transition: 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn.secondary {
  background: #fff;
  color: #5f6780;
  border: 1px solid #dde1ef;
  box-shadow: none;
}

.btn.secondary:hover {
  border-color: #cdd3ea;
}

.btn.ghost {
  background: #f7f8ff;
  color: #5f6780;
  border: 1px solid #e6e8f6;
  box-shadow: none;
}

.btn.ghost i {
  color: #5f6780;
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

input[type="file"] {
  display: none;
}

.dropzone {
  border: 2px dashed var(--line2);
  background: var(--soft);
  border-radius: 22px;
  padding: 28px;
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: 0.2s ease;
  margin-bottom: 18px;
}

.dropzone.dragover {
  border-color: var(--primary);
  background: #f2efff;
  transform: translateY(-1px);
}

.drop-inner {
  width: 100%;
  max-width: 520px;
}

.upload-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  margin: 0 auto 18px;
  background: linear-gradient(180deg, #7a68ff, #6958ff);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 28px;
  box-shadow: 0 12px 25px rgba(99, 91, 255, 0.25);
}

.dropzone h3 {
  font-size: 24px;
  margin-bottom: 10px;
  letter-spacing: -0.5px;
}

.dropzone p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 18px;
}

/* =========================
   RICH FILE CARD
========================= */

.file-card-wrap {
  margin-bottom: 18px;
}

.split-file-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: white;
  border: 1px solid #ececff;
  border-radius: 18px;
  padding: 16px;
  transition: 0.2s ease;
}

.split-file-entry:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 25px rgba(99, 91, 255, 0.06);
}

.split-file-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.split-pdf-mini {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #fff1f1;
  color: #ff5d5d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.split-file-meta {
  min-width: 0;
}

.split-file-name {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 500px;
}

.split-file-size {
  font-size: 12px;
  color: var(--muted);
}

.split-trash {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: none;
  background: transparent;
  color: #a0a8bc;
  cursor: pointer;
  transition: 0.2s ease;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}

.split-trash:hover {
  background: #fff1f1;
  color: #ff5d5d;
}

/* =========================
   ACTIONS BAR
========================= */

.actions-bar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  margin: 14px 0 16px;
}

.hint {
  margin-top: 12px;
  color: #9aa1b2;
  font-size: 12px;
  background: #9aa1b834;
  width: max-content;
  padding: 6px 12px;
  border-radius: 50px;
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.5;
}

.small-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* =========================
   PAGE THUMBNAILS
========================= */

.pages {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 12px;
}

.page {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 18px;
  padding: 10px;
  cursor: pointer;
  transition: 0.2s ease;
  text-align: left;
  position: relative;
  outline: none;
}

.page:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px rgba(99, 91, 255, 0.08);
}

.page.selected {
  border-color: var(--primary);
  box-shadow: 0 14px 30px rgba(105, 88, 255, 0.15);
}

.thumb {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #eef0ff;
  background: #f7f8ff;
}

.thumb img {
  width: 100%;
  height: 165px;
  object-fit: cover;
  display: block;
}

.page-number {
  position: absolute;
  left: 10px;
  top: 10px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(22, 27, 51, 0.9);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  z-index: 1;
}

.page-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}

.page-label {
  font-size: 13px;
  font-weight: 700;
}

.check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid #d4d8e8;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: white;
  transition: 0.2s ease;
}

.page.selected .check {
  border-color: var(--primary);
  background: var(--primary);
}

/* =========================
   SETTINGS
========================= */

.settings {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.settings {
  margin-top: 18px;
}

.panel {
  width: 100%;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fcfbff;
  padding: 18px;
}

.panel-title {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 12px;
}

label {
  display: block;
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 700;
  color: #3f4660;
}

.range-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

input[type="text"] {
  flex: 1;
  min-width: 180px;
  height: 46px;
  border-radius: 12px;
  border: 1px solid #dde1ef;
  padding: 0 14px;
  outline: none;
  font-family: "Inter", sans-serif;
  color: #4f566b;
  background: #fff;
}

select {
  width: 100%;
  height: 46px;
  border-radius: 12px;
  border: 1px solid #dde1ef;
  padding: 0 14px;
  outline: none;
  font-family: "Inter", sans-serif;
  color: #4f566b;
  background: #fff;
}

/* =========================
   EXPORT / PROGRESS
========================= */

.export-row {
  margin-top: 18px;
}

.big-btn {
  width: 100%;
  height: 54px;
  border: none;
  border-radius: 14px;
  color: white;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  background: linear-gradient(to right, #6958ff, #836dff) !important;
  box-shadow: 0 18px 30px rgba(99, 91, 255, 0.22);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: 0.25s ease;
}

.big-btn:hover {
  transform: translateY(-2px);
}

.big-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.progress {
  display: none;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  color: #6f7690;
  font-size: 13px;
}

.progress.show {
  display: flex;
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid #dcdfff;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.empty {
  margin-top: 14px;
  padding: 18px;
  border-radius: 18px;
  border: 1px dashed var(--line2);
  background: var(--soft);
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

/* =========================
   LARGE SCREENS
========================= */

@media (min-width: 1200px) {
  body {
    padding: 30px 3vw;
  }
  .page-container {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  .container {
    max-width: 94vw !important;
    width: 94vw !important;
  }
}

@media (min-width: 1440px) {
  body {
    padding: 36px 3vw;
  }
  .container {
    max-width: 94vw !important;
    width: 94vw !important;
  }
  h1 {
    font-size: 52px;
    letter-spacing: -2px;
  }
  .desc {
    font-size: 16px;
    max-width: 60vw;
  }
  .icon-box {
    width: 112px;
    height: 112px;
    border-radius: 26px;
  }
  .icon-box i {
    font-size: 64px;
  }
  .features {
    gap: 16px;
    margin-top: 20px;
  }
  .feature {
    font-size: 14px;
    padding: 13px 18px;
  }
  .tool {
    padding: 28px;
    border-radius: 28px;
  }
  .toolbar h2 {
    font-size: 22px;
  }
  .dropzone {
    min-height: 300px;
    padding: 34px;
    border-radius: 26px;
  }
  .upload-icon {
    width: 84px;
    height: 84px;
    font-size: 34px;
    margin-bottom: 22px;
  }
  .dropzone h3 {
    font-size: 28px;
  }
  .dropzone p {
    font-size: 15px;
    margin-bottom: 22px;
  }
  .btn {
    height: 52px;
    padding: 0 20px;
    font-size: 15px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
    gap: 16px;
  }
  .page {
    padding: 12px;
    border-radius: 20px;
  }
  .thumb img {
    height: 190px;
  }
  .page-number {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }
  .page-label {
    font-size: 14px;
  }
  .settings {
    margin-top: 24px;
    gap: 20px;
  }
  .panel {
    padding: 24px;
    border-radius: 22px;
  }
  .panel-title {
    font-size: 17px;
  }
  input[type="text"],
  select {
    height: 52px;
    font-size: 15px;
  }
  .shield {
    width: 60px;
    height: 60px;
    font-size: 26px;
  }
  .safe h4 {
    font-size: 17px;
  }
  .safe p {
    font-size: 14px;
  }
  .big-btn {
    height: 60px;
    font-size: 16px;
  }
  /* file card */
  .split-file-entry {
    padding: 20px 22px;
    border-radius: 20px;
  }
  .split-file-name {
    font-size: 15px;
  }
  .split-file-size {
    font-size: 13px;
  }
  .split-pdf-mini {
    width: 52px;
    height: 52px;
    font-size: 22px;
  }
}

@media (min-width: 1600px) {
  body {
    padding: 38px 3vw;
  }
  h1 {
    font-size: 58px;
    letter-spacing: -2.2px;
  }
  .desc {
    font-size: 17px;
  }
  .icon-box {
    width: 120px;
    height: 120px;
  }
  .icon-box i {
    font-size: 70px;
  }
  .tool {
    padding: 34px;
  }
  .toolbar h2 {
    font-size: 24px;
  }
  .dropzone {
    min-height: 340px;
  }
  .upload-icon {
    width: 90px;
    height: 90px;
    font-size: 36px;
  }
  .dropzone h3 {
    font-size: 32px;
  }
  .dropzone p {
    font-size: 16px;
  }
  .btn {
    height: 56px;
    font-size: 16px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  }
  .thumb img {
    height: 210px;
  }
  .panel {
    padding: 28px;
  }
  .panel-title {
    font-size: 18px;
  }
  input[type="text"],
  select {
    height: 56px;
  }
  .shield {
    width: 68px;
    height: 68px;
    font-size: 28px;
  }
  .safe h4 {
    font-size: 18px;
  }
  .big-btn {
    height: 66px;
    font-size: 17px;
  }
}

@media (min-width: 1920px) {
  body {
    padding: 42px 3vw;
  }
  h1 {
    font-size: 68px;
    letter-spacing: -2.5px;
  }
  .desc {
    max-width: 54vw;
    font-size: 18px;
    line-height: 1.8;
  }
  .hero {
    gap: 30px;
    margin-bottom: 30px;
  }
  .title-row {
    gap: 24px;
  }
  .icon-box {
    width: 132px;
    height: 132px;
    border-radius: 30px;
  }
  .icon-box i {
    font-size: 78px;
  }
  .features {
    gap: 20px;
    margin-top: 24px;
  }
  .feature {
    font-size: 16px;
    padding: 15px 22px;
    gap: 10px;
  }
  .feature i {
    font-size: 16px;
  }
  .tool {
    padding: 42px;
    border-radius: 34px;
  }
  .toolbar h2 {
    font-size: 28px;
  }
  .toolbar p {
    font-size: 15px;
  }
  .dropzone {
    min-height: 400px;
    border-width: 3px;
    border-radius: 30px;
  }
  .upload-icon {
    width: 104px;
    height: 104px;
    font-size: 40px;
    margin-bottom: 28px;
  }
  .dropzone h3 {
    font-size: 38px;
  }
  .dropzone p {
    font-size: 18px;
    margin-bottom: 28px;
  }
  .btn {
    height: 62px;
    padding: 0 24px;
    font-size: 17px;
    border-radius: 14px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
  }
  .page {
    padding: 14px;
    border-radius: 22px;
  }
  .thumb img {
    height: 240px;
  }
  .page-number {
    width: 36px;
    height: 36px;
    font-size: 16px;
    left: 14px;
    top: 14px;
  }
  .page-bottom {
    margin-top: 14px;
  }
  .page-label {
    font-size: 15px;
  }
  .check {
    width: 24px;
    height: 24px;
  }
  .settings {
    margin-top: 30px;
    gap: 24px;
  }
  .panel {
    padding: 34px;
    border-radius: 26px;
  }
  .panel-title {
    font-size: 20px;
    margin-bottom: 16px;
  }
  label {
    font-size: 15px;
    margin-bottom: 14px;
  }
  input[type="text"],
  select {
    height: 62px;
    font-size: 16px;
    border-radius: 14px;
    padding: 0 18px;
  }
  .shield {
    width: 76px;
    height: 76px;
    font-size: 32px;
    border-radius: 20px;
  }
  .safe h4 {
    font-size: 20px;
  }
  .safe p {
    font-size: 15px;
  }
  .big-btn {
    height: 72px;
    font-size: 19px;
    border-radius: 18px;
  }
  /* file card */
  .split-file-entry {
    padding: 24px 28px;
    border-radius: 22px;
  }
  .split-file-name {
    font-size: 18px;
    margin-bottom: 6px;
  }
  .split-file-size {
    font-size: 14px;
  }
  .split-pdf-mini {
    width: 60px;
    height: 60px;
    font-size: 26px;
    border-radius: 16px;
  }
  .split-trash {
    width: 48px;
    height: 48px;
    font-size: 18px;
  }
}

@media (min-width: 2560px) {
  body {
    padding: 52px 3vw;
  }
  h1 {
    font-size: 88px;
    letter-spacing: -3.5px;
  }
  .desc {
    max-width: 50vw;
    font-size: 22px;
    line-height: 1.9;
  }
  .hero {
    gap: 40px;
    margin-bottom: 40px;
  }
  .title-row {
    gap: 30px;
  }
  .icon-box {
    width: 170px;
    height: 170px;
    border-radius: 38px;
  }
  .icon-box i {
    font-size: 100px;
  }
  .features {
    gap: 26px;
    margin-top: 28px;
  }
  .feature {
    font-size: 20px;
    padding: 18px 28px;
    gap: 14px;
  }
  .feature i {
    font-size: 20px;
    border-width: 9px;
  }
  .tool {
    padding: 60px;
    border-radius: 44px;
  }
  .toolbar h2 {
    font-size: 34px;
  }
  .toolbar p {
    font-size: 18px;
    margin-top: 8px;
  }
  .dropzone {
    min-height: 520px;
    border-width: 4px;
    border-radius: 38px;
    padding: 50px;
  }
  .upload-icon {
    width: 132px;
    height: 132px;
    font-size: 52px;
    margin-bottom: 36px;
  }
  .dropzone h3 {
    font-size: 52px;
  }
  .dropzone p {
    font-size: 22px;
    margin-bottom: 36px;
  }
  .btn {
    height: 80px;
    padding: 0 32px;
    font-size: 20px;
    border-radius: 18px;
    gap: 12px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 26px;
  }
  .page {
    padding: 18px;
    border-radius: 28px;
  }
  .thumb img {
    height: 320px;
  }
  .page-number {
    width: 46px;
    height: 46px;
    font-size: 20px;
    left: 18px;
    top: 18px;
  }
  .page-bottom {
    margin-top: 18px;
  }
  .page-label {
    font-size: 18px;
  }
  .check {
    width: 30px;
    height: 30px;
  }
  .settings {
    margin-top: 40px;
    gap: 32px;
  }
  .panel {
    padding: 46px;
    border-radius: 34px;
  }
  .panel-title {
    font-size: 26px;
    margin-bottom: 22px;
  }
  label {
    font-size: 18px;
    margin-bottom: 18px;
  }
  input[type="text"],
  select {
    height: 78px;
    font-size: 20px;
    border-radius: 18px;
    padding: 0 24px;
  }
  .shield {
    width: 96px;
    height: 96px;
    font-size: 40px;
    border-radius: 26px;
  }
  .safe h4 {
    font-size: 24px;
  }
  .safe p {
    font-size: 18px;
    line-height: 1.6;
  }
  .big-btn {
    height: 90px;
    font-size: 24px;
    border-radius: 22px;
  }
  /* file card */
  .split-file-entry {
    padding: 32px 38px;
    border-radius: 28px;
  }
  .split-file-name {
    font-size: 23px;
    margin-bottom: 7px;
  }
  .split-file-size {
    font-size: 18px;
  }
  .split-pdf-mini {
    width: 76px;
    height: 76px;
    font-size: 34px;
    border-radius: 20px;
  }
  .split-trash {
    width: 60px;
    height: 60px;
    font-size: 26px;
    border-radius: 16px;
  }
}

/* =========================
   SMALL / MOBILE
========================= */

@media (max-width: 980px) {
  .hero {
    flex-direction: column;
    align-items: flex-start;
  }
  .settings,
  .export-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  body {
    padding: 14px;
  }
  .main-card {
    padding: 18px;
    border-radius: 22px;
  }
  h1 {
    font-size: 34px;
  }
  .dropzone h3 {
    font-size: 20px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }
}

@media (max-width: 425px) {
  body {
    padding: 10px;
    font-size: 13px;
  }
  .main-card {
    padding-bottom: 6px;
  }
  h1 {
    font-size: 28px;
    line-height: 1.15;
    letter-spacing: -1px;
  }
  .desc {
    font-size: 13px;
    line-height: 1.6;
  }
  .feature {
    font-size: 11px;
    padding: 7px 8px;
    gap: 5px;
  }
  .feature i {
    font-size: 11px;
    border-width: 5px;
  }
  .tool {
    padding: 14px;
    border-radius: 18px;
  }
  .toolbar {
    gap: 12px;
  }
  .toolbar h2 {
    font-size: 16px;
  }
  .toolbar p {
    font-size: 12px;
  }
  .dropzone {
    min-height: 200px;
    padding: 18px;
    border-radius: 18px;
  }
  .upload-icon {
    width: 58px;
    height: 58px;
    font-size: 24px;
    margin-bottom: 14px;
  }
  .dropzone h3 {
    font-size: 20px;
    letter-spacing: -0.5px;
  }
  .dropzone p {
    font-size: 12px;
    margin-bottom: 14px;
  }
  .btn {
    height: 42px;
    padding: 0 14px;
    font-size: 13px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(105px, 1fr));
    gap: 10px;
  }
  .page {
    padding: 8px;
    border-radius: 14px;
  }
  .thumb img {
    height: 130px;
  }
  .page-number {
    width: 24px;
    height: 24px;
    font-size: 11px;
    left: 6px;
    top: 6px;
  }
  .page-label {
    font-size: 12px;
  }
  .check {
    width: 18px;
    height: 18px;
  }
  .panel {
    padding: 14px;
    border-radius: 16px;
  }
  .panel-title {
    font-size: 14px;
    margin-bottom: 10px;
  }
  label {
    font-size: 12px;
    margin-bottom: 6px;
  }
  input[type="text"],
  select {
    height: 42px;
    font-size: 13px;
  }
  .shield {
    width: 44px;
    height: 44px;
    font-size: 18px;
    border-radius: 12px;
  }
  .safe h4 {
    font-size: 14px;
  }
  .safe p {
    font-size: 12px;
  }
  .big-btn {
    height: 48px;
    font-size: 14px;
  }
  /* file card */
  .split-file-entry {
    padding: 12px 14px;
    border-radius: 14px;
  }
  .split-file-name {
    font-size: 13px;
  }
  .split-file-size {
    font-size: 11px;
  }
  .split-pdf-mini {
    width: 38px;
    height: 38px;
    font-size: 16px;
    border-radius: 10px;
  }
  .split-trash {
    width: 36px;
    height: 36px;
    font-size: 14px;
    border-radius: 10px;
  }
}

@media (max-width: 375px) {
  body {
    padding: 8px;
    font-size: 12.5px;
  }
  h1 {
    font-size: 25px;
    line-height: 1.2;
  }
  .desc {
    font-size: 12px;
  }
  .feature {
    font-size: 10.5px;
    padding: 6px 7px;
  }
  .dropzone {
    min-height: 180px;
    padding: 16px;
    border-radius: 16px;
  }
  .upload-icon {
    width: 52px;
    height: 52px;
    font-size: 22px;
  }
  .dropzone h3 {
    font-size: 18px;
  }
  .dropzone p {
    font-size: 11.5px;
  }
  .btn {
    height: 40px;
    font-size: 12.5px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(95px, 1fr));
  }
  .thumb img {
    height: 115px;
  }
  .page-number {
    width: 22px;
    height: 22px;
    font-size: 10px;
  }
  .page-label {
    font-size: 11px;
  }
  .panel {
    padding: 12px;
  }
  .panel-title {
    font-size: 13px;
  }
  input[type="text"],
  select {
    height: 40px;
    font-size: 12.5px;
  }
  .shield {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  .safe h4 {
    font-size: 13px;
  }
  .safe p {
    font-size: 11px;
  }
  .big-btn {
    height: 46px;
    font-size: 13px;
  }
  /* file card */
  .split-file-entry {
    padding: 10px 12px;
  }
  .split-file-name {
    font-size: 12px;
  }
  .split-file-size {
    font-size: 10.5px;
  }
  .split-pdf-mini {
    width: 34px;
    height: 34px;
    font-size: 15px;
  }
  .split-trash {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 325px) {
  body {
    padding: 6px;
    font-size: 12px;
  }
  h1 {
    font-size: 23px;
    line-height: 1.18;
  }
  .desc {
    font-size: 11.5px;
  }
  .feature {
    font-size: 10px;
    padding: 5px 6px;
    gap: 4px;
  }
  .tool {
    padding: 10px;
    border-radius: 14px;
  }
  .toolbar h2 {
    font-size: 15px;
  }
  .dropzone {
    min-height: 160px;
    padding: 14px;
    border-radius: 14px;
  }
  .upload-icon {
    width: 46px;
    height: 46px;
    font-size: 20px;
    margin-bottom: 10px;
  }
  .dropzone h3 {
    font-size: 16px;
  }
  .dropzone p {
    font-size: 10.5px;
    margin-bottom: 12px;
  }
  .btn {
    height: 38px;
    padding: 0 10px;
    font-size: 12px;
    gap: 5px;
  }
  .pages {
    grid-template-columns: repeat(auto-fill, minmax(85px, 1fr));
    gap: 8px;
  }
  .page {
    padding: 6px;
    border-radius: 12px;
  }
  .thumb img {
    height: 100px;
  }
  .page-number {
    width: 20px;
    height: 20px;
    font-size: 9px;
    left: 4px;
    top: 4px;
  }
  .page-label {
    font-size: 10px;
  }
  .check {
    width: 16px;
    height: 16px;
  }
  .panel {
    padding: 10px;
    border-radius: 12px;
  }
  .panel-title {
    font-size: 12px;
    margin-bottom: 8px;
  }
  label {
    font-size: 10.5px;
    margin-bottom: 5px;
  }
  input[type="text"],
  select {
    height: 38px;
    font-size: 12px;
    border-radius: 10px;
    padding: 0 10px;
  }
  .shield {
    width: 36px;
    height: 36px;
    font-size: 14px;
    border-radius: 10px;
  }
  .safe h4 {
    font-size: 12px;
  }
  .safe p {
    font-size: 10px;
  }
  .big-btn {
    height: 42px;
    font-size: 12px;
    border-radius: 10px;
  }
}

/* =========================
   DARK THEME
========================= */

body.dark {
  color-scheme: dark;
  --bg: #0b1020;
  --card: #11172a;
  --card-2: #0f1628;
  --text: #e6ebff;
  --muted: #a8b1cc;
  --muted-2: #8d97b4;
  --border: #24304a;
  --border-2: #2d3853;
  --primary: #8b7bff;
  --primary-2: #a18fff;
  --primary-soft: #1a2140;
  --success: #32d583;
  --danger: #ff6b6b;
  --overlay-bg: #0f162a;
}

body.dark {
  background:
    radial-gradient(circle at top, rgba(139, 123, 255, 0.14), transparent 35%),
    var(--bg);
  color: var(--text);
}

body.dark .container {
  color: var(--text);
}

body.dark .tool,
body.dark .panel,
body.dark .dropzone,
body.dark .progress,
body.dark .empty {
  background: rgba(17, 23, 42, 0.96);
  border: 1px solid var(--border);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.28);
}

body.dark .title-row h1,
body.dark .toolbar-left h2,
body.dark .panel-title,
body.dark .stat,
body.dark .toolbar-left p,
body.dark .desc,
body.dark .hint,
body.dark .empty {
  color: var(--text);
}

body.dark .desc,
body.dark .toolbar-left p,
body.dark .hint,
body.dark .empty {
  color: var(--muted);
}

body.dark .icon-box,
body.dark .shield {
  background: #17213a;
  color: #ffffff;
}

body.dark .features {
  background: transparent !important;
  border: none !important;
}
body.dark .feature {
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  border: 1px solid var(--border);
}
body.dark .feature i {
  color: var(--primary-2);
  border-color: transparent !important;
}

body.dark .toolbar {
  border-bottom-color: var(--border);
}

body.dark .btn.secondary,
body.dark .btn.ghost {
  background: #10182d;
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.24);
}
body.dark .btn.secondary:hover,
body.dark .btn.ghost:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: #121c34;
}

body.dark .dropzone {
  background: linear-gradient(180deg, #11172a, #0e1526);
  border: 1.5px dashed #2a3550;
}
body.dark .dropzone:hover,
body.dark .dropzone.drag-over {
  border-color: var(--primary);
  background: #121b33;
}
body.dark .drop-inner h3 {
  color: var(--text);
}
body.dark .drop-inner p {
  color: var(--muted);
}

/* Dark — new file card */
body.dark .split-file-entry {
  background: #111827;
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}
body.dark .split-file-name {
  color: #f8fafc;
}
body.dark .split-file-size {
  color: #94a3b8;
}
body.dark .split-pdf-mini {
  background: rgba(239, 68, 68, 0.12);
  color: #f87171;
}
body.dark .split-trash {
  background: #1e293b;
  color: #e2e8f0;
}

body.dark .hint strong {
  color: #ffffff;
}
body.dark .small-actions {
  gap: 10px;
}

body.dark .pages {
  background: transparent;
}
body.dark .page {
  background: #10182d;
  border: 1px solid var(--border);
  color: var(--text);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}
body.dark .page:hover {
  border-color: rgba(139, 123, 255, 0.4);
}
body.dark .page.selected {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 123, 255, 0.15);
}
body.dark .thumb {
  border-color: rgba(148, 163, 184, 0.14);
  background: #0b1120;
}
body.dark .page-label {
  color: var(--text);
}
body.dark .page-number {
  background: rgba(15, 22, 40, 0.9);
  color: #e2e8f0;
}
body.dark .check {
  border-color: #475569;
}
body.dark .page.selected .check {
  border-color: var(--primary);
  background: var(--primary);
}

body.dark .settings {
  gap: 16px;
}
body.dark .panel {
  background: rgba(17, 23, 42, 0.96);
}
body.dark .panel.safe {
  background: linear-gradient(180deg, #10182d, #0e1526);
}
body.dark .panel label {
  color: var(--muted);
}
body.dark .panel h4 {
  color: var(--text);
}
body.dark .panel p {
  color: var(--muted);
}

body.dark input[type="text"],
body.dark select {
  background: #10182d;
  color: var(--text);
  border: 1px solid var(--border);
}
body.dark input[type="text"]::placeholder {
  color: var(--muted-2);
}
body.dark input[type="text"]:focus,
body.dark select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(139, 123, 255, 0.16);
  outline: none;
}
body.dark select option {
  background: #10182d;
  color: var(--text);
}

body.dark .big-btn {
  background: linear-gradient(
    to right,
    var(--primary),
    var(--primary-2)
  ) !important;
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.28);
}

body.dark .progress {
  background: #111b31;
  border: 1px solid var(--border);
}
body.dark .progress span {
  color: var(--muted);
}
body.dark .spinner {
  border-color: rgba(255, 255, 255, 0.18);
  border-top-color: var(--primary);
}

body.dark .empty {
  background: linear-gradient(180deg, #10182d, #0e1526);
  border: 1px dashed #2a3550;
  color: var(--muted);
}

body.dark .fa-bolt,
body.dark .fa-shield-heart,
body.dark .fa-layer-group,
body.dark .fa-file-zipper,
body.dark .fa-cloud-arrow-up,
body.dark .fa-check-double,
body.dark .fa-rotate,
body.dark .fa-eraser {
  color: var(--primary-2);
}

body.dark hr,
body.dark .divider {
  border-color: var(--border);
}
body.dark .toolbar,
body.dark .actions-bar,
body.dark .range-row {
  gap: 12px;
}
body.dark ::selection {
  background: rgba(139, 123, 255, 0.35);
  color: #ffffff;
}
body.dark .upload-icon i {
  color: #fff;
}
@media (max-width: 500px) {
  .btn.secondary {
    background: #fff;
    color: #5f6780;
    border: 1px solid #dde1ef;
    box-shadow: none;

    width: 100%;
  }
}

@media (max-width: 1041px) {
  .small-actions {
    width: 100%;
  }

  .small-actions .btn {
    flex: 1;
    justify-content: center;
  }
}
@media (max-width: 600px) {
  .page-container {
    padding-left: 0px !important;
    padding-right: 0px !important;
    padding-top: 0px !important;
  }
}
