 /* =========================
       CSS RESET & BASE STYLES
       ========================= */
    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }

    body {
      font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
      overflow-x: hidden;
      min-height: 100vh;
      height: 100vh;
      overflow-y: hidden;
    }

    /* =========================
       BACKGROUND LAYER
       ========================= */
    .background-layer {
      position: fixed;
      inset: 0;
      z-index: 0;
      background-image: url('assets/bg_mobile.webp');
      background-size: cover;
      background-position: center;
      background-repeat: no-repeat;
    }

    .background-overlay {
      position: absolute;
      inset: 0;
      background-color: rgba(0, 0, 0, 0.2);
    }

    /* =========================
       MAIN CONTAINER
       ========================= */
    .container {
      position: relative;
      z-index: 1;
      height: 100vh;
      display: flex;
      flex-direction: column;
      align-items: center;
      padding: 8vh 24px 24vh;
      justify-content: space-between;
    }

    /* =========================
       TITLE
       ========================= */
    .title {
      font-family: 'Germania One', 'Impact', 'Arial Black', sans-serif;
      font-size: 54px;
      line-height: 1;
      color: #f9e26e;
      text-align: center;
      text-shadow: 6px 6px 0px #333;
      max-width: 309px;
      letter-spacing: 0.02em;
    }

    /* =========================
       CARD
       ========================= */
    .card {
      background-color: rgba(63, 63, 63, 0.1);
      backdrop-filter: blur(10px);
      border-radius: 32px;
      padding: 24px;
      width: 100%;
      max-width: 345px;
    }

    /* Error message */
    .error-message {
      background-color: rgba(183, 59, 24, 0.9);
      color: white;
      padding: 12px 16px;
      border-radius: 12px;
      margin-bottom: 16px;
      font-size: 14px;
      line-height: 1.4;
      text-align: center;
      display: none;
    }

    .error-message.visible {
      display: block;
    }

    /* =========================
       FORM ELEMENTS
       ========================= */
    .form-container {
      display: flex;
      flex-direction: column;
      gap: 24px;
    }

    .input-wrapper {
      position: relative;
    }

    .name-input {
      width: 100%;
      padding: 13px;
      background-color: white;
      border: none;
      border-radius: 12px;
      font-size: 18px;
      text-align: center;
      color: #333;
      outline: none;
    }

    .name-input::placeholder {
      color: #9b9b9b;
    }

    /* Custom autocomplete dropdown */
    .autocomplete-list {
      position: absolute;
      top: 100%;
      left: 0;
      right: 0;
      background-color: white;
      border-radius: 12px;
      margin-top: 4px;
      box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
      max-height: 200px;
      overflow-y: auto;
      z-index: 10;
      display: none;
    }

    .autocomplete-list.visible {
      display: block;
    }

    .autocomplete-item {
      padding: 12px;
      cursor: pointer;
      font-size: 16px;
      text-align: center;
      color: #333;
    }

    .autocomplete-item:hover {
      background-color: #f0f0f0;
    }

    .autocomplete-item:first-child {
      border-radius: 12px 12px 0 0;
    }

    .autocomplete-item:last-child {
      border-radius: 0 0 12px 12px;
    }

    .draw-button {
      width: 100%;
      padding: 8px 48px;
      background-color: #b73b18;
      border: none;
      border-radius: 12px;
      font-family: 'Germania One', 'Impact', 'Arial Black', sans-serif;
      font-size: 24px;
      color: white;
      cursor: pointer;
      transition: transform 0.1s, background-color 0.2s;
    }

    .draw-button:hover {
      background-color: #a03315;
    }

    .draw-button:active {
      transform: scale(0.98);
    }

    /* =========================
       RESULT STATE
       ========================= */
    .result-container {
      display: none;
      flex-direction: column;
      gap: 20px;
      align-items: center;
      text-align: center;
    }

    .result-container.visible {
      display: flex;
    }

    .result-greeting {
      font-size: 24px;
      color: white;
      font-weight: 600;
      text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    }

    .result-recipient {
      font-size: 32px;
      color: #f9e26e;
      font-weight: bold;
      text-shadow: 2px 2px 0px black;
      padding: 16px;
      background-color: rgba(0, 0, 0, 0.3);
      border-radius: 12px;
      width: 100%;
    }

    .result-hint {
      font-size: 16px;
      color: #fff;
      font-style: italic;
      text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    }

    .back-button {
      margin-top: 8px;
      padding: 12px 32px;
      background-color: rgba(255, 255, 255, 0.2);
      border: 2px solid white;
      border-radius: 12px;
      color: white;
      font-size: 16px;
      cursor: pointer;
      transition: background-color 0.2s;
    }

    .back-button:hover {
      background-color: rgba(255, 255, 255, 0.3);
    }

    /* =========================
       RESET LINK
       ========================= */
    .reset-link {
      margin-top: 16px;
      text-align: center;
    }

    .reset-link a {
      color: rgba(255, 255, 255, 0.6);
      font-size: 12px;
      text-decoration: none;
      cursor: pointer;
      transition: color 0.2s;
    }

    .reset-link a:hover {
      color: rgba(255, 255, 255, 0.9);
      text-decoration: underline;
    }

    /* =========================
       DESKTOP RESPONSIVE
       ========================= */
    @media (min-width: 768px) {
    .background-layer{
              background-image: url('assets/bg_desktop.webp');
    }
      .container {
        padding: 8vh 5vw;
        gap: 30vh;
        justify-content: flex-start;
      }

      .title {
        font-size: 92px;
        max-width: 884px;
      }

      .card {
        max-width: 742px;
        padding: 48px;
      }

      .form-container {
        flex-direction: row;
        align-items: stretch;
      }

      .input-wrapper {
        flex: 1;
      }

      .draw-button {
        flex-shrink: 0;
        width: auto;
      }

      .error-message {
        font-size: 16px;
      }
    }