@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&display=swap');

/* ============================================================
   Excel Converter Suite — CLAYMORPHISM style
   Soft, puffy, toy-like 3D: thick borders, hard offset shadows,
   inner highlights. All scoped under .x2p
   ============================================================ */
.x2p {
    --xc-blue: #5b8cff;
    --xc-blue-dark: #3a63d8;
    --xc-blue-deep: #2f4fb8;
    --xc-violet: #8b7cf6;
    --xc-mint: #34d399;
    --xc-peach: #fb923c;
    --xc-ink: #1e2a4a;
    --xc-soft: #44507a;
    --xc-muted: #7c86a8;
    --xc-card: #eef2ff;
    --xc-card-border: #d5deff;
    max-width: 880px;
    margin: 2rem auto;
    color: var(--xc-ink);
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
}

/* [hidden] must always win over component display rules (e.g. .x2p-progress{display:flex}) */
.x2p [hidden] { display: none !important; }

/* ---------- Dropzone : big clay card ---------- */
.x2p-drop {
    position: relative;
    background: var(--xc-card);
    border: 3px solid var(--xc-card-border);
    border-radius: 32px;
    padding: 3.25rem 2rem;
    text-align: center;
    cursor: pointer;
    box-shadow:
        inset 3px 3px 10px rgba(255, 255, 255, .95),
        inset -5px -5px 14px rgba(140, 160, 220, .28),
        10px 14px 30px rgba(110, 130, 200, .28);
    transition: transform .2s, box-shadow .25s;
    overflow: hidden;
}
.x2p-drop:hover,
.x2p-drop:focus-visible {
    transform: translateY(-3px) scale(1.005);
    box-shadow:
        inset 3px 3px 10px rgba(255, 255, 255, .95),
        inset -5px -5px 14px rgba(140, 160, 220, .28),
        14px 20px 38px rgba(110, 130, 200, .36);
    outline: none;
}
.x2p-drop.x2p-dragover {
    transform: scale(1.02);
    border-color: var(--xc-blue);
    box-shadow:
        inset 3px 3px 10px rgba(255, 255, 255, .95),
        inset -5px -5px 14px rgba(91, 140, 255, .35),
        14px 20px 38px rgba(91, 140, 255, .4);
}
.x2p-drop-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: linear-gradient(145deg, #ffffff, #e3e9ff);
    border: 3px solid #d5deff;
    color: var(--xc-blue);
    margin-bottom: 1.1rem;
    box-shadow:
        inset 2px 2px 6px rgba(255, 255, 255, 1),
        inset -3px -3px 8px rgba(140, 160, 220, .3),
        6px 8px 18px rgba(110, 130, 200, .3);
    transition: transform .25s;
}
.x2p-drop:hover .x2p-drop-icon { transform: translateY(-5px) rotate(-4deg); }
.x2p-drop-icon svg { width: 44px; height: 44px; }
.x2p-drop-title {
    position: relative;
    font-size: 1.6rem;
    font-weight: 900;
    letter-spacing: -.01em;
}
.x2p-drop-sub { position: relative; color: var(--xc-muted); margin-top: .6rem; font-size: 1rem; font-weight: 600; }

/* chunky 3D clay button */
.x2p-browse {
    display: inline-block;
    margin-top: .35rem;
    padding: .6rem 1.8rem;
    border-radius: 999px;
    background: linear-gradient(145deg, #6d9bff, #4a78f0);
    border: 3px solid var(--xc-blue-dark);
    color: #fff !important;
    font-weight: 800;
    font-size: 1rem;
    text-decoration: none;
    cursor: pointer;
    box-shadow:
        inset 2px 2px 5px rgba(255, 255, 255, .5),
        inset -2px -2px 5px rgba(0, 0, 0, .12),
        0 6px 0 var(--xc-blue-deep),
        0 12px 22px rgba(74, 120, 240, .4);
    transition: transform .12s, box-shadow .12s;
}
.x2p-browse:hover { transform: translateY(-2px); box-shadow:
        inset 2px 2px 5px rgba(255, 255, 255, .5),
        inset -2px -2px 5px rgba(0, 0, 0, .12),
        0 8px 0 var(--xc-blue-deep),
        0 16px 26px rgba(74, 120, 240, .45); }
.x2p-browse:active { transform: translateY(4px); box-shadow:
        inset 2px 2px 5px rgba(255, 255, 255, .4),
        inset -2px -2px 5px rgba(0, 0, 0, .15),
        0 2px 0 var(--xc-blue-deep),
        0 6px 14px rgba(74, 120, 240, .35); }

/* ---------- Error : clay alert ---------- */
.x2p-error {
    margin-top: 1.2rem;
    padding: 1rem 1.25rem;
    border-radius: 20px;
    background: #ffe9e9;
    border: 3px solid #ffc9c9;
    color: #b91c1c;
    font-size: .95rem;
    font-weight: 700;
    box-shadow:
        inset 2px 2px 6px rgba(255, 255, 255, .8),
        6px 8px 18px rgba(220, 120, 120, .25);
}

/* ---------- Panel : clay card ---------- */
.x2p-panel {
    margin-top: 1.4rem;
    background: #f4f6ff;
    border: 3px solid var(--xc-card-border);
    border-radius: 30px;
    padding: 1.75rem;
    box-shadow:
        inset 3px 3px 10px rgba(255, 255, 255, .9),
        inset -5px -5px 14px rgba(140, 160, 220, .22),
        10px 14px 32px rgba(110, 130, 200, .25);
}

/* file chip : mint clay pill */
.x2p-filebar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.4rem;
    padding: .85rem 1.15rem;
    border-radius: 999px;
    background: #dcfce7;
    border: 3px solid #a7f3c7;
    box-shadow:
        inset 2px 2px 6px rgba(255, 255, 255, .85),
        inset -3px -3px 8px rgba(52, 211, 153, .25),
        5px 7px 16px rgba(52, 211, 153, .22);
}
.x2p-filename {
    font-weight: 800;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #166534;
    display: flex;
    align-items: center;
    gap: .55rem;
    min-width: 0;
}
.x2p-filename::before {
    content: "";
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(145deg, #4ade80, #22c55e);
    border: 2.5px solid #16a34a;
    box-shadow:
        inset 1.5px 1.5px 3px rgba(255, 255, 255, .6),
        0 3px 0 #15803d;
}
.x2p-link {
    background: #fff;
    border: 2.5px solid var(--xc-card-border);
    border-radius: 999px;
    padding: .45rem 1.1rem;
    color: var(--xc-soft);
    font-family: inherit;
    font-size: .85rem;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 4px 0 #c6d2f7, 0 8px 14px rgba(110, 130, 200, .2);
    transition: transform .12s, box-shadow .12s;
}
.x2p-link:hover { transform: translateY(-1px); }
.x2p-link:active { transform: translateY(3px); box-shadow: 0 1px 0 #c6d2f7; }

/* worksheet select : clay input */
/* worksheet + page size + orientation */
.x2p-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 1.4rem; }
.x2p-field {
    display: flex;
    flex-direction: column;
    gap: .45rem;
    font-size: .82rem;
    font-weight: 800;
    color: var(--xc-muted);
    text-transform: uppercase;
    letter-spacing: .06em;
}
.x2p-field select {
    appearance: none;
    -webkit-appearance: none;
    font-family: inherit;
    padding: .8rem 2.6rem .8rem 1.1rem;
    border: 3px solid var(--xc-card-border);
    border-radius: 18px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--xc-ink);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235b8cff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") right 1rem center/20px no-repeat;
    cursor: pointer;
    box-shadow:
        inset 2px 2px 6px rgba(140, 160, 220, .18),
        0 5px 0 #dbe4ff,
        0 10px 18px rgba(110, 130, 200, .18);
    transition: transform .12s, box-shadow .12s;
}
.x2p-field select:focus { outline: none; border-color: var(--xc-blue); }
.x2p-field select:active { transform: translateY(3px); box-shadow: inset 2px 2px 6px rgba(140,160,220,.25), 0 2px 0 #dbe4ff; }

/* ---------- Preview : carved-in clay well ---------- */
.x2p-preview-wrap { margin-bottom: 1.6rem; }
.x2p-preview-title {
    font-weight: 900;
    margin-bottom: .6rem;
    font-size: .82rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--xc-muted);
}
.x2p-preview {
    max-height: 340px;
    overflow: auto;
    border: 3px solid var(--xc-card-border);
    border-radius: 22px;
    background: #fff;
    box-shadow:
        inset 4px 4px 14px rgba(140, 160, 220, .28),
        inset -3px -3px 10px rgba(255, 255, 255, .9);
}
.x2p-preview table { border-collapse: separate; border-spacing: 0; width: 100%; font-size: .88rem; }
.x2p-preview th, .x2p-preview td {
    border-bottom: 2px solid #e8edff;
    border-right: 2px solid #e8edff;
    padding: .6rem .75rem;
    text-align: left;
    white-space: nowrap;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.x2p-preview th {
    background: linear-gradient(180deg, #dbe6ff, #c9d8ff);
    color: var(--xc-blue-deep);
    font-weight: 800;
    position: sticky;
    top: 0;
    z-index: 1;
}
.x2p-preview tbody tr:nth-child(even) td { background: #f7f9ff; }
.x2p-preview tbody tr:hover td { background: #e9efff; }
.x2p-empty { padding: 1.4rem; color: var(--xc-muted); text-align: center; font-weight: 700; }

/* ---------- Convert button : big chunky clay ---------- */
.x2p-btn {
    display: block;
    width: 100%;
    padding: 1.1rem 1.25rem;
    border: 3px solid var(--xc-blue-dark);
    border-radius: 22px;
    background: linear-gradient(145deg, #6d9bff 0%, #4a78f0 100%);
    color: #fff;
    font-family: inherit;
    font-size: 1.25rem;
    font-weight: 900;
    letter-spacing: .02em;
    cursor: pointer;
    box-shadow:
        inset 3px 3px 7px rgba(255, 255, 255, .5),
        inset -3px -3px 7px rgba(0, 0, 0, .14),
        0 8px 0 var(--xc-blue-deep),
        0 18px 32px rgba(74, 120, 240, .42);
    transition: transform .12s, box-shadow .12s, filter .2s;
}
.x2p-btn:hover:not(:disabled) { transform: translateY(-2px); filter: brightness(1.06); box-shadow:
        inset 3px 3px 7px rgba(255, 255, 255, .5),
        inset -3px -3px 7px rgba(0, 0, 0, .14),
        0 10px 0 var(--xc-blue-deep),
        0 22px 36px rgba(74, 120, 240, .48); }
.x2p-btn:active:not(:disabled) { transform: translateY(6px); box-shadow:
        inset 3px 3px 7px rgba(255, 255, 255, .4),
        inset -3px -3px 7px rgba(0, 0, 0, .16),
        0 2px 0 var(--xc-blue-deep),
        0 8px 18px rgba(74, 120, 240, .35); }
.x2p-btn:disabled { opacity: .65; cursor: wait; transform: none; }
.x2p-progress {
    display: flex; align-items: center; justify-content: center; gap: .7rem;
    margin-top: 1.2rem; color: var(--xc-muted); font-size: .95rem; font-weight: 700;
}
.x2p-spinner {
    width: 26px; height: 26px;
    border: 4px solid #dbe4ff;
    border-top-color: var(--xc-blue);
    border-radius: 50%;
    box-shadow: inset 1px 1px 3px rgba(140,160,220,.4);
    animation: x2p-spin .8s linear infinite;
}
@keyframes x2p-spin { to { transform: rotate(360deg); } }

/* privacy : tiny clay pill */
.x2p-privacy { display: block; width: fit-content; margin: 1.4rem auto 0; padding: .6rem 1.25rem; border-radius: 999px; background: #fff8e6; border: 3px solid #ffe3a3; color: #92610f; font-size: .88rem; font-weight: 700; box-shadow: inset 2px 2px 5px rgba(255,255,255,.9), 4px 6px 14px rgba(220,180,90,.25); }

/* ---------- How-to : clay step cards, playful tints ---------- */
.x2p-how { margin-top: 3rem; }
.x2p-how h2 { font-size: 1.6rem; font-weight: 900; letter-spacing: -.01em; margin-bottom: 1.2rem; text-align: center; }
.x2p-how ol {
    list-style: none;
    counter-reset: x2p-step;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.1rem;
}
.x2p-how li {
    counter-increment: x2p-step;
    position: relative;
    border-radius: 26px;
    padding: 1.5rem 1.25rem 1.3rem;
    margin: 0;
    font-size: .95rem;
    font-weight: 600;
    color: var(--xc-soft);
    border: 3px solid;
    box-shadow:
        inset 2px 2px 8px rgba(255, 255, 255, .9),
        inset -4px -4px 10px rgba(140, 160, 220, .18),
        8px 10px 24px rgba(110, 130, 200, .22);
}
.x2p-how li:nth-child(1) { background: #e3ecff; border-color: #c3d4ff; }
.x2p-how li:nth-child(2) { background: #ece7ff; border-color: #d5cbff; }
.x2p-how li:nth-child(3) { background: #dcfbe9; border-color: #b4f0cd; }
.x2p-how li::before {
    content: counter(x2p-step);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-weight: 900;
    font-size: 1.25rem;
    color: #fff;
    margin-bottom: .9rem;
    border: 3px solid;
    box-shadow:
        inset 2px 2px 4px rgba(255, 255, 255, .55),
        inset -2px -2px 4px rgba(0, 0, 0, .12),
        0 5px 0 rgba(0, 0, 0, .14),
        0 10px 18px rgba(0, 0, 0, .18);
}
.x2p-how li:nth-child(1)::before { background: linear-gradient(145deg, #6d9bff, #4a78f0); border-color: var(--xc-blue-dark); }
.x2p-how li:nth-child(2)::before { background: linear-gradient(145deg, #a58bff, #8b7cf6); border-color: #6d5fe0; }
.x2p-how li:nth-child(3)::before { background: linear-gradient(145deg, #4ade9e, #34d399); border-color: #1ea872; }
.x2p-how li strong { display: block; color: var(--xc-ink); font-weight: 900; margin-bottom: .15rem; font-size: 1.02rem; }

/* ---------- FAQ : clay accordion ---------- */
.x2p-faq-block { margin-top: 0; }
.x2p-faq h2 { font-size: 1.6rem; font-weight: 900; letter-spacing: -.01em; margin-bottom: 1.2rem; text-align: center; }
.x2p-qa {
    background: #f4f6ff;
    border: 3px solid var(--xc-card-border);
    border-radius: 22px;
    margin-bottom: .85rem;
    overflow: hidden;
    box-shadow:
        inset 2px 2px 8px rgba(255, 255, 255, .9),
        inset -4px -4px 10px rgba(140, 160, 220, .16),
        6px 8px 20px rgba(110, 130, 200, .18);
    transition: border-color .2s;
}
.x2p-qa[open] { border-color: #aebfff; background: #eef2ff; }
.x2p-qa summary {
    padding: 1.05rem 1.25rem;
    font-weight: 800;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}
.x2p-qa summary::-webkit-details-marker { display: none; }
.x2p-qa summary::after {
    content: "+";
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(145deg, #6d9bff, #4a78f0);
    border: 3px solid var(--xc-blue-dark);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 900;
    line-height: 32px;
    text-align: center;
    box-shadow:
        inset 1.5px 1.5px 3px rgba(255, 255, 255, .55),
        0 4px 0 var(--xc-blue-deep),
        0 8px 14px rgba(74, 120, 240, .35);
    transition: transform .25s;
}
.x2p-qa[open] summary::after { content: "−"; transform: rotate(180deg); }
.x2p-qa p { padding: 0 1.3rem 1.25rem; margin: 0; color: var(--xc-soft); font-weight: 600; }

/* ---------- Responsive ---------- */
@media (max-width: 700px) {
    .x2p-how ol { grid-template-columns: 1fr; }
    .x2p-grid { grid-template-columns: 1fr; }
    .x2p-drop { padding: 2.25rem 1.25rem; border-radius: 26px; }
    .x2p-drop-title { font-size: 1.3rem; }
    .x2p-drop-icon { width: 76px; height: 76px; }
    .x2p-panel { padding: 1.2rem; border-radius: 24px; }
    .x2p-filebar { flex-direction: column; align-items: stretch; border-radius: 24px; }
    .x2p-link { text-align: center; }
    .x2p-btn { font-size: 1.1rem; }
}
