.gif-crop-resize-page{
  max-width:1280px;
  margin:0 auto;
  padding:34px 18px 46px;
  color:var(--text);
}

.gif-crop-resize-page *{
  box-sizing:border-box;
}

.gif-crop-resize-page h1{
  margin:0 0 12px;
  text-align:center;
  font-size:clamp(34px,5vw,52px);
  line-height:1.05;
  text-shadow:0 0 24px rgba(120,90,255,.22);
}

.gcr-intro{
  max-width:900px;
  margin:0 auto 28px;
  text-align:center;
  color:#c9c9d6;
  font-size:clamp(15px,2vw,18px);
  line-height:1.65;
}

/* ------------------------------------------------ */
/* Upload */
/* ------------------------------------------------ */

.gcr-upload{
  position:relative;
  margin:0 auto 24px;
  max-width:920px;
  padding:28px 22px;
  text-align:center;
  background:
    linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.025));
  border:2px dashed rgba(255,255,255,.15);
  border-radius:22px;
  transition:.18s;
  cursor:pointer;
}

.gcr-upload:hover,
.gcr-upload.gcr-dragover{
  border-color:var(--link);
  background:
    linear-gradient(180deg,rgba(120,90,255,.10),rgba(255,255,255,.04));
  box-shadow:
    0 0 0 3px rgba(120,90,255,.15),
    0 18px 40px rgba(0,0,0,.22);
}

.gcr-upload-label{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  width:100%;
  cursor:pointer;
  font-size:clamp(18px,2.4vw,23px);
  font-weight:800;
  color:#fff;
}

.gcr-upload-label i{
  color:var(--link);
  font-size:28px;
}

.gcr-upload input{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  opacity:0;
  cursor:pointer;
}

.gcr-upload p{
  margin:12px 0 0;
  color:#b9bbca;
  font-size:14px;
}

/* ------------------------------------------------ */
/* Layout */
/* ------------------------------------------------ */

.gcr-layout{
  display:flex;
  flex-direction:column;
  gap:18px;
}
.gcr-preview-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
  align-items:stretch;
}
.gcr-canvas-wrap{
  position:relative;
  display:flex;
  justify-content:center;
  align-items:center;
  height:440px;
  min-height:440px;
  max-height:440px;
  overflow:hidden;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.08);
  background:
    linear-gradient(45deg,#22252e 25%,transparent 25%),
    linear-gradient(-45deg,#22252e 25%,transparent 25%),
    linear-gradient(45deg,transparent 75%,#22252e 75%),
    linear-gradient(-45deg,transparent 75%,#22252e 75%);
  background-size:28px 28px;
  background-position:0 0,0 14px,14px -14px,-14px 0;
}
.gcr-canvas-wrap canvas{
  width:auto;
  height:auto;
  max-width:100%;
  max-height:100%;
  display:block;
}
@media(max-width:900px){
  .gcr-preview-grid{
    grid-template-columns:1fr;
  }
  .gcr-canvas-wrap{
    height:340px;
    min-height:340px;
    max-height:340px;
  }
}
@media(max-width:640px){
  .gcr-canvas-wrap{
    height:260px;
    min-height:260px;
    max-height:260px;
  }
}

.gcr-panel,
.gcr-section{
  background:var(--content);
  border:1px solid rgba(255,255,255,.08);
  border-radius:18px;
  box-shadow:
    0 18px 42px rgba(0,0,0,.20);
}

.gcr-panel{
  padding:16px;
}

.gcr-panel-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:15px;
  margin-bottom:14px;
}

.gcr-panel-head h2{
  margin:0;
  color:var(--link);
  font-size:20px;
}

.gcr-panel-head span{
  color:#aeb0c2;
  font-size:13px;
}

/* ------------------------------------------------ */
/* Preview */
/* ------------------------------------------------ */

.gcr-empty-preview{
  position:absolute;
  inset:0;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  gap:14px;
  color:#aeb0c2;
  text-align:center;
  pointer-events:none;
}

.gcr-empty-preview i{
  font-size:42px;
  color:var(--link);
}

.gcr-empty-preview span{
  max-width:260px;
  line-height:1.5;
}

.gcr-help{
  margin:12px 2px 0;
  color:#bfc0ce;
  font-size:13px;
  line-height:1.55;
}

/* ------------------------------------------------ */
/* Controls */
/* ------------------------------------------------ */

.gcr-controls{
  padding-bottom:18px;
}

.gcr-check{
  display:flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  user-select:none;
  color:#d9d9e6;
  font-size:13px;
}

.gcr-check input{
  accent-color:var(--link);
}

.gcr-presets{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(140px,1fr));
  gap:10px;
  margin-bottom:18px;
}

.gcr-presets button{
  height:40px;
  border:none;
  border-radius:12px;
  background:#2d3040;
  color:#fff;
  cursor:pointer;
  font-weight:600;
  transition:.16s;
}

.gcr-presets button:hover{
  background:var(--link);
  transform:translateY(-2px);
}

.gcr-control-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(170px,1fr));
  gap:14px;
}

.gcr-mini-field{
  display:flex;
  flex-direction:column;
  gap:7px;
}

.gcr-mini-field span{
  font-size:13px;
  color:#d8d8e6;
  font-weight:700;
}

.gcr-mini-field input,
.gcr-mini-field select{
  width:100%;
  height:42px;
  padding:0 12px;
  color:#fff;
  background:#181b24;
  border:1px solid rgba(255,255,255,.08);
  border-radius:11px;
  outline:none;
  transition:.16s;
}

.gcr-mini-field input:focus,
.gcr-mini-field select:focus{
  border-color:var(--link);
  box-shadow:0 0 0 3px rgba(120,90,255,.18);
}

.gcr-mini-field input[type=color]{
  padding:4px;
  cursor:pointer;
}

.gcr-mini-field select option{
  background:#181b24;
  color:#fff;
}

.gcr-options{
  margin-top:18px;
  padding:15px;
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:12px;
  border-radius:14px;
  background:rgba(255,255,255,.03);
  border:1px solid rgba(255,255,255,.06);
}

/* ------------------------------------------------ */
/* Actions */
/* ------------------------------------------------ */

.gcr-actions{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:12px;
  margin-top:20px;
}

.gcr-actions button{
  height:46px;
  border:none;
  border-radius:13px;
  font-size:15px;
  font-weight:700;
  color:#fff;
  cursor:pointer;
  transition:.16s;
}

.gcr-actions button:hover:not(:disabled){
  transform:translateY(-2px);
  filter:brightness(1.08);
}

.gcr-actions button:disabled{
  opacity:.45;
  cursor:not-allowed;
}

.gcr-action-primary{
  background:linear-gradient(135deg,#7b4dff,#5e85ff);
}

.gcr-action-download{
  background:linear-gradient(135deg,#12b86c,#18d77f);
}

.gcr-action-soft{
  background:#35394a;
}

.gcr-action-danger{
  background:linear-gradient(135deg,#c7375b,#eb516b);
}

/* ------------------------------------------------ */
/* Status */
/* ------------------------------------------------ */

.gcr-status{
  margin-top:18px;
  padding:12px 16px;
  border-radius:12px;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.08);
  color:#d4d4e2;
  font-size:14px;
  line-height:1.5;
}

/* ------------------------------------------------ */
/* Info */
/* ------------------------------------------------ */

.gcr-section{
  margin-top:22px;
  padding:20px;
}

.gcr-section h2{
  margin:0 0 14px;
  color:var(--link);
}

.gcr-section p{
  margin:0 0 14px;
  color:#c9c9d6;
  line-height:1.65;
}

.gcr-section ul{
  margin:0;
  padding-left:22px;
}

.gcr-section li{
  margin-bottom:10px;
  color:#c9c9d6;
  line-height:1.6;
}

/* ------------------------------------------------ */
/* Mobile */
/* ------------------------------------------------ */

@media(max-width:900px){
  .gcr-actions{
    grid-template-columns:repeat(2,1fr);
  }
}

@media(max-width:640px){

  .gif-crop-resize-page{
    padding:28px 12px 40px;
  }

  .gcr-panel-head{
    flex-direction:column;
    align-items:flex-start;
  }

  .gcr-actions{
    grid-template-columns:1fr;
  }

  .gcr-options{
    grid-template-columns:1fr;
  }

}
