:root {
    --primary: #a3cef1;
    --secondary: #f6bd60;
    --accent: #f28482;
    --background: #f9f9f9;
    --card: #fff;
    --text: #22223b;
    --muted: #b5b5b5;
    --success: #84a59d;
  }
  
  html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    font-family: 'Segoe UI', Arial, sans-serif;
    min-height: 100vh;
  }
  
  body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-width: 100vw;
  }
  
  .header {
    background: rgba(255,255,255,0.7);
    color: var(--text);
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    box-shadow: 0 2px 8px rgba(163,206,241,0.08);
    font-weight: 600;
    letter-spacing: 1px;
  }
  
  .header-title {
    font-size: 2rem;
    font-weight: bold;
    color: var(--accent);
    letter-spacing: 2px;
  }
  
  .header-login {
    font-size: 1rem;
    color: var(--text);
    opacity: 0.7;
    cursor: pointer;
    transition: opacity 0.2s;
  }
  
  .header-login:hover {
    opacity: 1;
  }
  
  .center-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
  }
  
  .main-card {
    background: var(--card);
    max-width: 420px;
    width: 90%;
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(163,206,241,0.18);
    border: none;
    padding: 40px 32px 32px 32px;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 18px;
    animation: fadeIn 1.2s cubic-bezier(.4,0,.2,1);
  }
  
  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(40px);}
    to { opacity: 1; transform: translateY(0);}
  }
  
  .main-title {
    text-align: center;
    font-size: 1.6rem;
    font-weight: bold;
    color: var(--text);
    margin-bottom: 10px;
    letter-spacing: 1px;
  }
  
  .label {
    font-size: 1rem;
    color: var(--text);
    margin-bottom: 4px;
    display: block;
    font-weight: 500;
  }
  
  .input-box, .dropdown-select {
    width: 100%;
    height: 44px;
    border-radius: 12px;
    border: 1.5px solid var(--primary);
    background: #f7faff;
    font-size: 1rem;
    padding: 0 14px;
    margin-bottom: 0;
    box-sizing: border-box;
    color: var(--text);
    transition: border 0.2s;
    outline: none;
  }
  
  .input-box:focus, .dropdown-select:focus {
    border: 1.5px solid var(--accent);
    background: #fff;
  }
  
  .dropdown-group {
    position: relative;
  }
  
  .dropdown-select {
    appearance: none;
    cursor: pointer;
  }
  
  .dropdown-arrow {
    position: absolute;
    right: 18px;
    top: 36px;
    pointer-events: none;
    font-size: 20px;
    color: var(--muted);
  }
  
  .shorten-btn {
    width: 100%;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--secondary) 100%);
    color: #fff;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    font-weight: bold;
    letter-spacing: 1px;
    box-shadow: 0 2px 8px rgba(242,132,130,0.08);
    transition: background 0.2s, transform 0.1s;
    margin-top: 8px;
  }
  
  .shorten-btn:hover {
    background: linear-gradient(90deg, var(--secondary) 0%, var(--accent) 100%);
    transform: translateY(-2px) scale(1.02);
  }
  
  .result-box {
    width: 100%;
    min-height: 44px;
    border-radius: 12px;
    background: #eaf4f4;
    border: 1.5px solid var(--success);
    font-size: 1rem;
    color: var(--success);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    box-sizing: border-box;
    opacity: 0;
    pointer-events: none;
    margin-top: 8px;
    transition: opacity 0.5s;
    font-weight: 500;
    letter-spacing: 1px;
  }
  
  .result-box.visible {
    opacity: 1;
    pointer-events: auto;
    animation: fadeInResult 0.7s;
  }
  
  @keyframes fadeInResult {
    from { opacity: 0; transform: scale(0.95);}
    to { opacity: 1; transform: scale(1);}
  }
  
  .loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
    margin-bottom: 8px;
    min-height: 80px;
    width: 100%;
    gap: 10px;
  }
  
  .loading-message {
    color: var(--accent);
    font-weight: 500;
    font-size: 1rem;
    animation: pulse 1.5s infinite;
    text-align: center;
  }
  
  @keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
  }
  
  .spinner {
    width: 32px;
    height: 32px;
    border: 4px solid #eaf4f4;
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
  }
  
  @keyframes spin {
    0% { transform: rotate(0deg);}
    100% { transform: rotate(360deg);}
  }
  
  .footer {
    text-align: center;
    color: #999;
    font-size: 1rem;
    opacity: 0.7;
    letter-spacing: 1px;
    background: rgba(255,255,255,0.7);
    padding: 20px;
  }
  @media (max-width: 600px) {
    .main-card {
      padding: 24px 8px 18px 8px;
      border-radius: 16px;
    }
    .header {
      padding: 0 12px;
      font-size: 1rem;
    }
  }