:root {
  --pg-glass: linear-gradient(155deg, rgb(255 255 255 / .072), transparent 42%),
    linear-gradient(155deg, #142118, #0a120d 78%);
  --pg-glass-edge: rgb(191 221 199 / .24);
  --pg-glass-shadow: inset 0 1px 0 rgb(255 255 255 / .075), 0 15px 38px rgb(0 0 0 / .21);
  --pg-glass-ease: cubic-bezier(.2, .75, .25, 1);
}

.pangea-dl {
  background: radial-gradient(ellipse at 13% 0, #14231a 0, transparent 40rem), var(--bg);
}

.pangea-dl .dl-header {
  border-color: rgb(194 223 198 / .14);
  background: linear-gradient(145deg, #142018, #080e0a 67%);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .045), 0 12px 26px rgb(0 0 0 / .16);
}

.pangea-dl .dl-header .top-inner { min-height: 77px; gap: 18px; }
.pangea-dl .dl-header .brand { color: var(--ink); flex-shrink: 0; }

.pangea-dl .top-inner .pg-nav {
  gap: 4px;
  padding: 4px;
  border: 1px solid rgb(192 222 199 / .15);
  border-radius: 22px;
  background: rgb(1 9 5 / .36);
  box-shadow: inset 0 1px 3px rgb(0 0 0 / .35);
}

.pg-nav .pg-nav-link,
.pg-nav .pg-nav-link[aria-current] {
  position: relative;
  isolation: isolate;
  gap: 8px;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 17px;
  background: transparent;
  box-shadow: none;
  padding: 6px 15px;
  transition: transform .22s var(--pg-glass-ease), color .22s;
}

.pg-nav .pg-nav-link::before {
  content: '';
  pointer-events: none;
  position: absolute;
  z-index: -1;
  inset: -1px;
  border: 1px solid rgb(153 194 159 / .24);
  border-radius: inherit;
  background: linear-gradient(160deg, rgb(218 242 220 / .13), rgb(155 206 160 / .04));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .075), 0 4px 13px rgb(0 0 0 / .18);
  opacity: .52;
  transition: opacity .24s var(--pg-glass-ease);
}

.pg-nav .pg-nav-link > .icon { color: #bbd4bc; flex: none; }
.pg-nav .pg-nav-link[aria-current] > .icon { color: var(--accent); }
.pg-nav .pg-nav-link[aria-current]::before {
  opacity: 1;
  border-color: rgb(213 250 36 / .42);
  background: radial-gradient(ellipse at 50% 100%, #57632660, transparent 77%), linear-gradient(160deg, #30412b, #162519);
  box-shadow: inset 0 1px 0 rgb(250 255 207 / .13), 0 5px 14px rgb(0 0 0 / .23);
}

@media (hover:hover) {
  .pg-nav .pg-nav-link:hover { background: transparent; border-color: transparent; filter: none; transform: translateY(-1px); }
  .pg-nav .pg-nav-link:hover::before { opacity: 1; }
  .pg-nav .pg-nav-link:active { transform: translateY(1px) scale(.99); }
}

.pangea-dl .pg-hero {
  border: 1px solid rgb(159 181 159 / .17);
  border-radius: clamp(20px, 3vw, 32px);
  box-shadow: var(--pg-glass-shadow);
}

.pangea-dl .dl-editor .pg-hero { margin-bottom: clamp(14px, 2.1vw, 24px); }
.pangea-dl .dl-editor .pg-hero p { margin-bottom: 0; }
.pangea-dl .dl-editor-work { gap: clamp(12px, 1.85vw, 20px); }

.pangea-dl :is(.panel, .admin-bar, .studio-top > section, .activity, .pg-account-card) {
  background: var(--pg-glass);
  border-color: var(--pg-glass-edge);
  border-radius: clamp(19px, 2.8vw, 28px);
  box-shadow: var(--pg-glass-shadow);
}

.pg-secondary > .history-grid:has(> .panel) {
  gap: clamp(12px, 1.8vw, 20px);
  align-items: stretch;
}

.pg-secondary > .history-grid > .panel {
  grid-template-rows: auto auto 1fr auto;
  justify-items: start;
}

.pg-studio .history-grid { gap: clamp(12px, 1.8vw, 20px); }
.pg-studio .activity {
  border: 1px solid var(--pg-glass-edge);
  padding: clamp(14px, 2.6vw, 24px);
}

.pangea-dl .dl-editor-upload {
  align-self: start;
  padding: clamp(11px, 1.55vw, 17px);
  overflow: visible;
}

.pangea-dl .dl-editor-upload .dl-file-picker {
  margin: 12px 0 5px;
  grid-template-rows: auto;
  justify-items: center;
}

.pangea-dl .dl-editor .file-name:empty { display: none; }
.pangea-dl .dl-editor .file-name { text-align: center; }
.pangea-dl .dl-editor .file-help { padding-bottom: 2px; }

.pangea-dl .dl-editor-upload .dl-editor-preview {
  min-height: 0;
  display: block;
  border-radius: clamp(13px, 1.8vw, 21px);
  overflow: hidden;
}

.pangea-dl .dl-editor-upload .dl-editor-preview:has(> #archivo-vista:not([hidden])) {
  border-radius: clamp(13px, 1.8vw, 21px);
  border: 1px solid rgb(191 221 199 / .17);
  margin: 0;
  padding: 0;
}

.pangea-dl .dl-editor-preview #archivo-vacio {
  margin: 0;
  min-height: clamp(250px, 30vw, 398px);
  align-content: center;
  justify-items: center;
  gap: 18px;
  padding: 24px 18px;
  text-align: center;
  display: grid;
  border: 1px solid rgb(185 218 181 / .20);
  border-radius: inherit;
  background: radial-gradient(ellipse at 50% 28%, rgb(147 183 77 / .14), transparent 62%),
    radial-gradient(circle, rgb(210 235 191 / .13) 1px, transparent 1.5px) 0 0 / 17px 17px,
    #09130c;
  cursor: pointer;
}

.pangea-dl .dl-editor-preview #archivo-vacio[hidden],
.pangea-dl .dl-editor-preview #archivo-vista[hidden] { display: none !important; }

.pg-upload-symbol {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  color: #e2f6bc;
  width: 69px;
  height: 69px;
  border: 1px solid rgb(225 251 181 / .3);
  border-radius: 23px;
  background: linear-gradient(145deg, #485e3a, #1b2c21 82%);
  box-shadow: inset 0 1px 0 rgb(240 255 205 / .18), 0 15px 30px rgb(0 0 0 / .4);
  transition: transform .3s var(--pg-glass-ease);
}

.pg-upload-symbol::before {
  content: '';
  z-index: -1;
  position: absolute;
  inset: -7px;
  border: 1px solid rgb(210 242 152 / .15);
  border-radius: 27px;
  transform: rotate(-12deg);
}

.pg-upload-copy { display: grid; gap: 5px; color: var(--ink); }
.pg-upload-copy strong { font-size: 1.12rem; font-weight: 800; letter-spacing: -.035em; }
.pg-upload-copy > span { font-size: .86rem; color: var(--muted); }

.pangea-dl .dl-file-picker .file-label,
.pangea-dl .dl-mode-face {
  border: 1px solid rgb(184 214 191 / .26);
  border-radius: 14px;
  background: linear-gradient(155deg, #29392d, #162119);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .085), 0 4px 12px rgb(0 0 0 / .18);
  transition: transform .22s var(--pg-glass-ease);
}

.pangea-dl .dl-file-picker .file-label { gap: 8px; }
.pangea-dl .dl-file-picker .file-label > .icon { color: var(--accent); }
.pangea-dl .dl-mode-face { min-height: 50px; }

.pangea-dl .dl-mode-control input:checked + .dl-mode-face,
.pangea-dl .dl-editor-submit .btn.primary {
  background: linear-gradient(155deg, #edff9d -15%, #d5fa24 56%, #badb16 117%);
  box-shadow: inset 0 1px 0 rgb(253 255 216 / .67), 0 7px 22px rgb(188 233 34 / .15);
}

.pangea-dl .dl-editor-submit .btn.primary { border-radius: 14px; min-height: 53px; }
.pangea-dl .dl-editor .field textarea { border-radius: 13px; min-height: 52px; background: rgb(5 13 8 / .63); }

@media (hover:hover) {
  .pangea-dl #archivo-vacio:hover .pg-upload-symbol { transform: translateY(-4px) rotate(-4deg); }
  .pangea-dl .dl-file-picker .file-label:hover,
  .pangea-dl .dl-mode-face:hover,
  .pangea-dl .dl-editor-submit .btn.primary:hover:not(:disabled) { transform: translateY(-2px); }
}

@media (min-width:761px) and (prefers-reduced-transparency:no-preference) {
  @supports (backdrop-filter: blur(1px)) {
    .pangea-dl .top-inner .pg-nav { backdrop-filter: blur(10px); }
  }
}

@media (max-width:760px) {
  .pangea-dl .dl-header .top-inner { min-height: 60px; gap: 7px; }
  .pg-nav .pg-nav-link,
  .pg-nav .pg-nav-link[aria-current] { gap: 5px; min-width: 0; padding-inline: 8px; }
  .pg-nav .pg-nav-link > .icon { width: 14px; height: 14px; }
  .pangea-dl .dl-editor-preview #archivo-vacio { min-height: clamp(195px, 49vw, 285px); }
  .pg-upload-symbol { width: 58px; height: 58px; border-radius: 20px; }
  .pg-upload-symbol::before { inset: -6px; border-radius: 23px; }
}

@media (max-width:450px) {
  .pangea-dl .dl-header .top-inner { justify-content: flex-start; padding-block: 9px; }
  .pangea-dl .top-inner .pg-nav { display: flex; flex: 1 0 100%; flex-wrap: nowrap; justify-content: stretch; }
  .pg-nav .pg-nav-link { flex: 1 1 auto; font-size: .79rem; }
  .pg-nav:has(> :nth-child(4)) .pg-nav-link { padding-inline: 5px; }
  .pg-nav:has(> :nth-child(4)) .pg-nav-link > .icon { display: none; }
}

@media (prefers-reduced-motion:no-preference) {
  .dl-editor .pg-hero > :is(h1,p),
  .dl-editor .dl-editor-work > .panel { animation: pg-enter .46s var(--pg-glass-ease) both; }
  .dl-editor .pg-hero > p { animation-delay: .035s; }
  .dl-editor .dl-editor-work > .panel:first-child { animation-delay: .075s; }
  .dl-editor .dl-editor-work > .panel:last-child { animation-delay: .115s; }
  .dl-editor #archivo-vista[src]:not([hidden]) { animation: pg-enter .23s var(--pg-glass-ease) both; }
}

@media (prefers-reduced-motion:reduce) {
  .pangea-dl .pg-nav-link::before,
  .pangea-dl :is(.pg-nav-link, .pg-upload-symbol, .file-label, .dl-mode-face, .dl-editor-submit .btn.primary) {
    transition: none;
    transform: none !important;
  }
}

@media (forced-colors:active) {
  .pg-nav .pg-nav-link[aria-current] { border-color: Highlight; }
  .pangea-dl .dl-mode-control input:checked + .dl-mode-face { border-color: Highlight; }
}

@keyframes pg-enter {
  from { opacity: .55; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
