html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body.site-body {
  margin-bottom: 0;
}

.letter-spacing {
  letter-spacing: 0.08em;
}

.site-hero {
  background: linear-gradient(165deg, #f8f9fa 0%, #e7f1ff 45%, #fff 100%);
}

.site-hero-card {
  border-radius: 0.75rem;
}

.site-feature-list li {
  text-align: left;
}

.site-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.site-footer a {
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* Mobile / tablet: touch targets and readable tool UI */
@media (max-width: 991.98px) {
  .image-tool-page .btn-touch {
    min-height: 2.75rem;
    padding-top: 0.65rem;
    padding-bottom: 0.65rem;
    font-size: 1rem;
  }

  .image-tool-page .tool-card .card-body {
    padding: 1rem 1rem 1.25rem;
  }

  .image-tool-page input[type="file"].form-control-lg {
    min-height: 2.75rem;
    padding: 0.5rem 0.65rem;
  }
}

.image-tool-page .image-tool-title {
  font-size: 1.5rem;
  line-height: 1.25;
}

@media (min-width: 768px) {
  .image-tool-page .image-tool-title {
    font-size: 2rem;
  }
}

.image-tool-page .tool-form .form-text {
  font-size: 0.8125rem;
  line-height: 1.35;
}

/* Premium Styles */
.premium-hero {
    background: linear-gradient(135deg, #020617 0%, #1e1b4b 100%);
    color: #f8fafc;
    position: relative;
    overflow: hidden;
    padding: 6rem 0;
}

.premium-hero::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%; width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(99,102,241,0.15) 0%, rgba(0,0,0,0) 50%);
    animation: rotate-bg 30s linear infinite;
    z-index: 0;
}

@keyframes rotate-bg {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.premium-hero .container {
    position: relative;
    z-index: 1;
}

.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.5rem;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
}

.glass-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px -12px rgba(99,102,241,0.4);
}

.feature-icon-wrapper {
    width: 3.5rem; height: 3.5rem;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 1rem;
    background: linear-gradient(135deg, #6366f1 0%, #ec4899 100%);
    color: white;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 15px -3px rgba(99,102,241,0.3);
    transition: transform 0.3s;
}

.feature-icon-wrapper:hover {
    transform: scale(1.1) rotate(5deg);
}

.gradient-text {
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.btn-glowing {
    background: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    color: white;
    border: none;
    border-radius: 2rem;
    font-weight: 600;
    box-shadow: 0 4px 14px 0 rgba(99,102,241,0.39);
    transition: all 0.3s ease;
}

.btn-glowing:hover {
    box-shadow: 0 8px 25px rgba(99,102,241,0.6);
    transform: translateY(-2px);
    color: white;
}

.btn-glass {
    background: rgba(255,255,255,0.1);
    color: white;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 2rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s;
}

.btn-glass:hover {
    background: rgba(255,255,255,0.2);
    color: white;
    border-color: rgba(255,255,255,0.4);
}

.site-section-modern {
    background-color: #f8fafc;
    border-top: 1px solid #e2e8f0;
    padding: 6rem 0;
}

.step-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.03);
    transition: transform 0.3s;
    height: 100%;
}

.step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.06);
}

.step-number {
    font-size: 3rem;
    font-weight: 800;
    opacity: 0.1;
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    color: #6366f1;
}