

    :root {
      --gold: #c9a84c;
      --gold-light: #e8c97a;
      --gold-dark: #8b6914;
      --cream: #fdf6e8;
      --brown: #3d2b0e;
      --brown-light: #6b4c22;
      --ink: #1a1008;
      --shadow: rgba(61, 43, 14, 0.25);
    }

    * { margin: 0; padding: 0; box-sizing: border-box; }

    body {
      font-family: 'Tajawal', sans-serif;
      background-color: var(--cream);
      color: var(--ink);
      min-height: 100vh;
      overflow-x: hidden;
    }

    /* ─── Ornamental Background ─────────────────────── */
    body::before {
      content: '';
      position: fixed;
      inset: 0;
      background-image:
        radial-gradient(ellipse at 20% 20%, rgba(201,168,76,0.12) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 80%, rgba(201,168,76,0.10) 0%, transparent 55%),
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23c9a84c' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
      pointer-events: none;
      z-index: 0;
    }

    /* ─── Header ─────────────────────────────────────── */
    .header {
      position: relative;
      z-index: 1;
      text-align: center;
      padding: 36px 20px 20px;
    }

    .header-frame img { width: 200px; }

    .header-ornament {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 12px;
      margin: 16px 0 8px;
    }

    .header-ornament span {
      height: 1px;
      width: 70px;
      background: linear-gradient(to right, transparent, var(--gold), transparent);
    }

    .page-title {
      font-family: 'Amiri', serif;
      font-size: 1.8rem;
      font-weight: 700;
      color: var(--brown);
      text-shadow: 0 2px 6px rgba(201,168,76,0.3);
    }

    /* ─── Divider ─────────────────────────────────────── */
    .divider {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 14px;
      padding: 8px 24px 28px;
      position: relative;
      z-index: 1;
    }

    .divider-line {
      flex: 1;
      max-width: 260px;
      height: 1px;
      background: linear-gradient(to right, transparent, var(--gold-light), transparent);
    }

    .divider-gem {
      width: 8px;
      height: 8px;
      background: var(--gold);
      transform: rotate(45deg);
      border-radius: 1px;
    }

    /* ─── Main Layout ─────────────────────────────────── */
    .card-page {
      position: relative;
      z-index: 1;
      display: flex;
      flex-wrap: wrap;
      align-items: flex-start;
      justify-content: center;
      gap: 32px;
      padding: 0 24px 60px;
      max-width: 1000px;
      margin: 0 auto;
    }

    /* ─── Card Preview ────────────────────────────────── */
    .preview-wrap {
      flex: 1 1 320px;
      max-width: 420px;
      border-radius: 14px;
      overflow: hidden;
      box-shadow: 0 6px 28px var(--shadow);
      border: 2px solid rgba(201,168,76,0.3);
      animation: fadeUp 0.4s ease both;
    }

    .preview-wrap img {
      width: 100%;
      display: block;
    }

    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(18px); }
      to   { opacity: 1; transform: translateY(0); }
    }

    /* ─── Form Panel ──────────────────────────────────── */
    .form-panel {
      flex: 1 1 260px;
      max-width: 380px;
      background: rgba(201,168,76,0.07);
      border: 1px solid rgba(201,168,76,0.3);
      border-radius: 14px;
      padding: 32px 28px;
      box-shadow: 0 4px 20px var(--shadow);
      display: flex;
      flex-direction: column;
      gap: 20px;
      animation: fadeUp 0.4s ease 0.1s both;
    }

    .form-panel h1 {
      font-family: 'Amiri', serif;
      font-size: 1.5rem;
      font-weight: 700;
      color: var(--brown);
      text-align: center;
    }

    .form-panel input[type="text"] {
      width: 100%;
      padding: 12px 16px;
      font-size: 1rem;
      font-family: 'Tajawal', sans-serif;
      background: white;
      border: 1.5px solid var(--gold);
      border-radius: 8px;
      color: var(--brown);
      text-align: right;
      box-shadow: 0 2px 8px var(--shadow);
      transition: border-color 0.2s, box-shadow 0.2s;
      outline: none;
    }

    .form-panel input[type="text"]:focus {
      border-color: var(--gold-dark);
      box-shadow: 0 2px 14px rgba(201,168,76,0.35);
    }

    .form-panel input[type="text"]::placeholder {
      color: rgba(107, 76, 34, 0.45);
    }

    /* Download button */
    .form-panel input[type="submit"] {
      width: 100%;
      padding: 12px;
      font-size: 1.05rem;
      font-family: 'Tajawal', sans-serif;
      font-weight: 700;
      background: var(--gold);
      color: white;
      border: none;
      border-radius: 8px;
      cursor: pointer;
      box-shadow: 0 3px 12px rgba(201,168,76,0.4);
      transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    }

    .form-panel input[type="submit"]:hover {
      background: var(--gold-dark);
      transform: scale(1.03);
      box-shadow: 0 5px 18px rgba(201,168,76,0.5);
    }

    /* Back button */
    .back-btn {
      display: block;
      width: 100%;
      padding: 11px;
      font-size: 1rem;
      font-family: 'Tajawal', sans-serif;
      font-weight: 500;
      background: transparent;
      color: var(--brown);
      border: 1.5px solid var(--gold);
      border-radius: 8px;
      cursor: pointer;
      text-align: center;
      box-shadow: 0 2px 8px var(--shadow);
      transition: background 0.2s, color 0.2s, box-shadow 0.2s;
      text-decoration: none;
    }

    .back-btn:hover {
      background: var(--gold);
      color: white;
      box-shadow: 0 4px 16px rgba(201,168,76,0.5);
    }

    /* ─── Responsive ─────────────────────────────────── */
    @media (max-width: 600px) {
      .card-page { gap: 20px; padding: 0 14px 40px; }
      .form-panel { padding: 22px 18px; }
      .page-title { font-size: 1.4rem; }
    }
