/**
 * FELTOO Memorial Videos - Estilos UNIFICADOS v6
 * Mateixos colors i tipografies que blog/contact/FAQs
 * Tipografías: Fraunces + Satoshi
 * NOTA: El header ara ve del functions.php (feltoo_get_header)
 */

/* ==========================================================================
   Font Imports
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,wght@0,200;0,300;0,400;1,200;1,300;1,400&display=swap');
@import url('https://api.fontshare.com/v2/css?f[]=satoshi@300,400,500,700&display=swap');

/* ==========================================================================
   Variables UNIFICADES (iguals que blog/contact/FAQs)
   ========================================================================== */

:root {
    /* Colors principals - UNIFICATS */
    --feltoo-verde-oscuro: #415229;
    --feltoo-verde: #5a6b4f;
    --feltoo-verde-hover: #8b9d6f;
    --feltoo-crema: #f0ebe7;
    --feltoo-fondo: #FAFAF8;
    --feltoo-texto: #333;
    --feltoo-texto-light: #666;
    --feltoo-texto-muted: #888;
    --feltoo-linea: #e0e0e0;
    --feltoo-white: #FFFFFF;
    
    /* Colors derivats */
    --feltoo-card-bg: #f5f3f0;
    --feltoo-input-bg: #f8f7f5;
    --feltoo-border: #e5e2de;
    
    /* Radius i ombres */
    --feltoo-radius: 12px;
    --feltoo-radius-lg: 20px;
    --feltoo-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    --feltoo-shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.1);
    
    /* Tipografies - UNIFICADES */
    --font-fraunces: 'Fraunces', Georgia, serif;
    --font-satoshi: 'Satoshi', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ==========================================================================
   Body Background
   ========================================================================== */

body {
    background-color: var(--feltoo-fondo) !important;
}

/* ==========================================================================
   Page Container
   ========================================================================== */

.feltoo-page {
    background: var(--feltoo-fondo);
    min-height: 100vh;
}

.feltoo-app {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 30px;
    font-family: var(--font-satoshi);
    color: var(--feltoo-texto);
    background: var(--feltoo-fondo);
}

.feltoo-app *,
.feltoo-app *::before,
.feltoo-app *::after {
    box-sizing: border-box;
}

/* ==========================================================================
   Textos i Títols
   ========================================================================== */

.feltoo-step-intro {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 40px;
}

.feltoo-step-intro h1 {
    font-family: var(--font-satoshi);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--feltoo-verde);
    margin-bottom: 25px;
    font-weight: 500;
}

.feltoo-step-intro p {
    font-family: var(--font-satoshi);
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--feltoo-texto);
    font-style: normal;
    font-weight: 200;
}

/* ==========================================================================
   Steps Indicator
   ========================================================================== */

.feltoo-steps-indicator {
    display: flex;
    justify-content: center;
    gap: 80px;
    margin-bottom: 50px;
    padding: 0 20px;
}

.feltoo-step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.feltoo-step-label {
    font-family: var(--font-satoshi);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--feltoo-texto-muted);
}

.feltoo-step-name {
    font-family: var(--font-satoshi);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--feltoo-texto-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.feltoo-step-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--feltoo-texto-muted);
    background: transparent;
    margin-top: 6px;
    transition: all 0.3s ease;
}

.feltoo-step-indicator.active .feltoo-step-dot,
.feltoo-step-indicator.completed .feltoo-step-dot {
    background: var(--feltoo-verde);
    border-color: var(--feltoo-verde);
}

.feltoo-step-indicator.active .feltoo-step-name,
.feltoo-step-indicator.active .feltoo-step-label {
    color: var(--feltoo-texto);
}

/* ==========================================================================
   Steps Content
   ========================================================================== */

.feltoo-step {
    display: none;
}

.feltoo-step-active {
    display: block;
}

/* ==========================================================================
   STEP 1: Categories
   ========================================================================== */

.feltoo-categories {
    display: flex;
    flex-direction: column;
    gap: 35px;
    max-width: 950px;
    margin: 0 auto;
}

.feltoo-category-card {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 0;
    background: transparent;
    border-radius: var(--feltoo-radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feltoo-category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--feltoo-shadow-lg);
}

.feltoo-category-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border-radius: var(--feltoo-radius-lg) 0 0 var(--feltoo-radius-lg);
}

.feltoo-category-content {
    background: var(--feltoo-card-bg);
    padding: 40px 45px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-radius: 0 var(--feltoo-radius-lg) var(--feltoo-radius-lg) 0;
}

.feltoo-category-name {
    font-family: var(--font-fraunces);
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--feltoo-texto);
    margin-bottom: 18px;
}

.feltoo-category-desc {
    font-family: var(--font-satoshi);
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--feltoo-texto-light);
    line-height: 1.75;
    margin-bottom: 28px;
}

.feltoo-category-btn {
    font-family: var(--font-satoshi);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--feltoo-verde);
    color: var(--feltoo-white);
    padding: 14px 40px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    width: fit-content;
}

.feltoo-category-btn:hover {
    background: var(--feltoo-verde-oscuro);
    transform: translateY(-2px);
}

/* ==========================================================================
   STEP 2: Main Container (Preview + Form)
   ========================================================================== */

.feltoo-main-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 60px;
    align-items: start;
}

/* ==========================================================================
   Preview Column
   ========================================================================== */

.feltoo-preview-column {
    position: sticky;
    top: 30px;
}

.feltoo-preview-title {
    font-family: var(--font-satoshi);
    font-size: 1rem;
    font-weight: 500;
    color: var(--feltoo-texto);
    margin-bottom: 20px;
}

.feltoo-preview-wrapper {
    position: relative;
    width: 100%;
    max-width: 280px;
    aspect-ratio: 9/16;
    border-radius: var(--feltoo-radius-lg);
    overflow: hidden;
    box-shadow: var(--feltoo-shadow-lg);
    background: #1a1a2e;
}

.feltoo-preview-wrapper iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.feltoo-preview-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feltoo-replay-btn {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    z-index: 10;
}

.feltoo-replay-btn:hover {
    background: rgba(255,255,255,0.35);
}

.feltoo-replay-btn svg {
    width: 18px;
    height: 18px;
    fill: white;
}

.feltoo-preview-hint {
    margin-top: 15px;
    font-size: 0.8rem;
    color: var(--feltoo-texto-muted);
    text-align: center;
    max-width: 280px;
}

/* ==========================================================================
   Template Selector
   ========================================================================== */

.feltoo-template-selector {
    margin-top: 30px;
    max-width: 280px;
}

.feltoo-templates-title {
    font-family: var(--font-satoshi);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--feltoo-texto);
    margin-bottom: 14px;
}

.feltoo-templates {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.feltoo-template-thumb {
    cursor: pointer;
    border-radius: 8px;
    overflow: hidden;
    border: 3px solid transparent;
    transition: all 0.2s ease;
    background: var(--feltoo-card-bg);
}

.feltoo-template-thumb:hover {
    border-color: var(--feltoo-linea);
}

.feltoo-template-thumb.active {
    border-color: var(--feltoo-verde);
    box-shadow: 0 4px 15px rgba(90, 107, 79, 0.25);
}

.feltoo-template-thumb img {
    width: 100%;
    aspect-ratio: 9/16;
    object-fit: cover;
    display: block;
}

.feltoo-template-name {
    display: block;
    padding: 6px 4px;
    font-size: 0.65rem;
    text-align: center;
    color: var(--feltoo-texto-light);
    background: var(--feltoo-fondo);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ==========================================================================
   Form Column
   ========================================================================== */

.feltoo-form-column {
    padding-top: 0;
}

.feltoo-form-title {
    font-family: var(--font-fraunces);
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--feltoo-texto);
    margin-bottom: 30px;
}

.feltoo-form {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

/* ==========================================================================
   Image Upload Fields
   ========================================================================== */

.feltoo-images-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 10px;
}

.feltoo-field-image {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.feltoo-field-image > label {
    font-family: var(--font-satoshi);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--feltoo-texto);
}

.feltoo-field-image .required {
    color: #c0392b;
}

.feltoo-image-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.feltoo-image-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    aspect-ratio: 3/4;
    background: var(--feltoo-card-bg);
    border: 2px dashed var(--feltoo-linea);
    border-radius: var(--feltoo-radius);
    cursor: pointer;
    transition: all 0.2s ease;
}

.feltoo-image-label:hover {
    background: var(--feltoo-crema);
    border-color: var(--feltoo-verde-hover);
}

.feltoo-field-image.has-image .feltoo-image-label {
    background: var(--feltoo-verde);
    border: none;
}

.feltoo-image-icon {
    width: 32px;
    height: 32px;
    color: var(--feltoo-texto-muted);
}

.feltoo-field-image.has-image .feltoo-image-icon {
    color: var(--feltoo-white);
}

.feltoo-image-label-text {
    font-size: 0.75rem;
    color: var(--feltoo-texto-muted);
    text-align: center;
}

.feltoo-field-image.has-image .feltoo-image-label-text {
    color: var(--feltoo-white);
    font-weight: 500;
}

.feltoo-image-preview {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    border-radius: var(--feltoo-radius);
    display: none;
}

.feltoo-field-image.has-image .feltoo-image-preview {
    display: block;
}

.feltoo-field-image.has-image .feltoo-image-label {
    display: none;
}

/* ==========================================================================
   Form Fields
   ========================================================================== */

.feltoo-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.feltoo-field > label {
    font-family: var(--font-satoshi);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--feltoo-texto);
}

.feltoo-field .required {
    color: #c0392b;
    margin-left: 2px;
}

.feltoo-field input[type="text"],
.feltoo-field input[type="date"],
.feltoo-field textarea {
    padding: 14px 18px;
    border: 1px solid var(--feltoo-linea);
    border-radius: var(--feltoo-radius);
    font-size: 0.95rem;
    font-family: var(--font-satoshi);
    font-weight: 300;
    background: var(--feltoo-input-bg);
    color: var(--feltoo-texto);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.feltoo-field input:focus,
.feltoo-field textarea:focus {
    outline: none;
    border-color: var(--feltoo-verde);
    box-shadow: 0 0 0 3px rgba(90, 107, 79, 0.15);
}

.feltoo-field input::placeholder,
.feltoo-field textarea::placeholder {
    color: var(--feltoo-texto-muted);
}

.feltoo-field textarea {
    resize: vertical;
    min-height: 120px;
}

.feltoo-field-hint {
    font-family: var(--font-satoshi);
    font-size: 0.75rem;
    color: var(--feltoo-texto-muted);
    font-style: italic;
}

.feltoo-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.feltoo-separator {
    height: 1px;
    background: var(--feltoo-linea);
    margin: 10px 0;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.feltoo-submit {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.feltoo-submit-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
}

/* Botó principal i, a sota, la nota de la marca dels anuncis gratuïts */
.feltoo-submit-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.feltoo-submit-hint.feltoo-free-note {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--feltoo-texto);
}

.feltoo-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--feltoo-verde);
    color: var(--feltoo-white);
    border: none;
    padding: 16px 40px;
    font-size: 1rem;
    font-weight: 500;
    font-family: var(--font-satoshi);
    border-radius: 30px;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.feltoo-btn-primary:hover {
    background: var(--feltoo-verde-oscuro);
    transform: translateY(-2px);
}

.feltoo-btn-primary:active {
    transform: translateY(0);
}

.feltoo-btn-primary:disabled {
    background: var(--feltoo-linea);
    cursor: not-allowed;
    transform: none;
}

.feltoo-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--feltoo-crema);
    color: var(--feltoo-texto);
    border: none;
    padding: 16px 40px;
    font-size: 1rem;
    font-weight: 500;
    font-family: var(--font-satoshi);
    border-radius: 30px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.feltoo-btn-secondary:hover {
    background: var(--feltoo-linea);
}

.feltoo-submit-hint {
    font-family: var(--font-satoshi);
    font-size: 0.8rem;
    color: var(--feltoo-texto-muted);
    text-align: center;
}

.feltoo-submit-hint a {
    color: var(--feltoo-verde);
    text-decoration: none;
}

.feltoo-submit-hint a:hover {
    text-decoration: underline;
}

.feltoo-stripe-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    color: var(--feltoo-texto-muted);
}

.feltoo-stripe-badge img {
    height: 20px;
}

/* ==========================================================================
   Notices
   ========================================================================== */

.feltoo-notice {
    padding: 18px 25px;
    border-radius: var(--feltoo-radius);
    text-align: center;
    font-family: var(--font-satoshi);
}

.feltoo-notice-warning {
    background: #fef9e7;
    color: #9a7b0a;
    border: 1px solid #f7dc6f;
}

.feltoo-notice-success {
    background: #e8f5e9;
    color: var(--feltoo-verde-oscuro);
    border: 1px solid var(--feltoo-verde-hover);
}

.feltoo-notice-error {
    background: #ffebee;
    color: #c62828;
    border: 1px solid #ef9a9a;
}

/* Avís en tornar de Stripe quan falten dades (el bàner verd ve del CSS del lloc) */
#feltoo-success-banner.feltoo-payment-warning-banner {
    background: #fbf3e2;
    border-color: #d9b46a;
    color: #6b4f16;
}

/* ==========================================================================
   Progress Overlay
   ========================================================================== */

.feltoo-progress-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    padding: 20px;
}

.feltoo-progress-modal {
    background: var(--feltoo-white);
    border-radius: var(--feltoo-radius-lg);
    padding: 50px 40px;
    max-width: 420px;
    width: 100%;
    text-align: center;
}

.feltoo-progress-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--feltoo-crema);
    border-top: 4px solid var(--feltoo-verde);
    border-radius: 50%;
    animation: feltoo-spin 1s linear infinite;
    margin: 0 auto 25px;
}

@keyframes feltoo-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.feltoo-progress-title {
    font-family: var(--font-fraunces);
    font-size: 1.3rem;
    font-weight: 300;
    color: var(--feltoo-texto);
    margin-bottom: 20px;
}

.feltoo-progress-bar-container {
    width: 100%;
    height: 10px;
    background: var(--feltoo-crema);
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 15px;
}

.feltoo-progress-bar {
    height: 100%;
    background: var(--feltoo-verde);
    border-radius: 5px;
    width: 0%;
    transition: width 0.3s ease;
}

.feltoo-progress-text {
    color: var(--feltoo-texto-light);
    font-size: 0.9rem;
    margin: 0;
}

/* ==========================================================================
   Video Result Modal
   ========================================================================== */

.feltoo-result-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    padding: 20px;
}

.feltoo-result-modal {
    background: var(--feltoo-white);
    border-radius: var(--feltoo-radius-lg);
    padding: 35px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}

.feltoo-result-modal h2 {
    font-family: var(--font-fraunces);
    color: var(--feltoo-verde);
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 300;
}

.feltoo-result-modal video {
    width: 100%;
    max-height: 60vh;
    border-radius: var(--feltoo-radius);
    background: #000;
    margin-bottom: 20px;
}

.feltoo-download-btn {
    display: inline-block;
    text-decoration: none;
    margin-top: 10px;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.feltoo-close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    color: var(--feltoo-texto-muted);
    cursor: pointer;
    line-height: 1;
    padding: 5px;
}

.feltoo-close-btn:hover {
    color: var(--feltoo-texto);
}

/* ==========================================================================
   Remove the feltoo.com mark (modal de feltoo-remove-mark.js)
   ========================================================================== */

/* Per sobre del resultat del vídeo, que també és un .feltoo-result-overlay
   (amb dues classes: el CSS addicional del lloc en té una còpia de 999999) */
.feltoo-result-overlay.feltoo-rm-overlay {
    z-index: 1000001;
}

.feltoo-rm-overlay[hidden],
.feltoo-rm-modal [hidden] {
    display: none !important;
}

/* Previsualització 9:16. L'iframe no s'amaga mai amb display: none, perquè
   el preview.html s'escala a la mida de la seva finestra */
.feltoo-rm-preview {
    position: relative;
    width: min(220px, calc(36vh * 9 / 16));
    aspect-ratio: 9 / 16;
    margin: 0 auto 12px;
    border-radius: var(--feltoo-radius);
    overflow: hidden;
    background: var(--feltoo-crema);
}

.feltoo-rm-preview iframe,
.feltoo-rm-preview img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.feltoo-rm-preview iframe {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feltoo-rm-preview.is-animated iframe {
    opacity: 1;
}

.feltoo-rm-preview img {
    display: none;
    object-fit: cover;
}

.feltoo-rm-preview.is-still img {
    display: block;
}

.feltoo-rm-preview.is-none {
    display: none;
}

.feltoo-rm-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feltoo-rm-loading .feltoo-progress-spinner {
    width: 36px;
    height: 36px;
    margin: 0;
}

.feltoo-rm-preview.is-animated .feltoo-rm-loading,
.feltoo-rm-preview.is-still .feltoo-rm-loading {
    display: none;
}

.feltoo-rm-caption {
    margin: 0 0 18px;
    font-size: 0.9rem;
    color: var(--feltoo-texto-light);
}

.feltoo-rm-price {
    margin: 0 0 4px;
    font-family: var(--font-fraunces);
    font-size: 2rem;
    font-weight: 300;
    color: var(--feltoo-texto);
}

.feltoo-rm-includes {
    list-style: none;
    margin: 0 0 18px;
    padding: 0;
    font-size: 0.9rem;
    color: var(--feltoo-texto-light);
}

.feltoo-rm-includes li {
    margin: 2px 0;
}

.feltoo-rm-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.feltoo-rm-form label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--feltoo-texto);
}

.feltoo-rm-form input {
    width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    border: 1px solid var(--feltoo-border);
    border-radius: 8px;
    background: var(--feltoo-input-bg);
    font-family: var(--font-satoshi);
    font-size: 1rem;
}

.feltoo-rm-form button,
.feltoo-rm-modal [data-rm-use-version] {
    width: 100%;
    margin-top: 6px;
}

.feltoo-rm-secure {
    margin: 12px 0 0;
    font-size: 0.8rem;
    color: var(--feltoo-texto-muted);
}

.feltoo-rm-confirm {
    margin: 0 0 12px;
    font-size: 0.95rem;
    color: var(--feltoo-texto);
}

.feltoo-rm-message {
    margin: 14px 0 0;
    padding: 12px;
    border-radius: 8px;
    background: #ffebee;
    color: #c62828;
    font-size: 0.9rem;
}

/* Botó sota Download, al resultat del formulari */
.feltoo-rm-result {
    margin-top: 12px;
}

/* ==========================================================================
   Image Cropper Modal
   ========================================================================== */

.feltoo-crop-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.feltoo-crop-modal.active {
    display: flex;
}

.feltoo-crop-modal-content {
    background: var(--feltoo-white);
    border-radius: var(--feltoo-radius-lg);
    padding: 30px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.feltoo-crop-title {
    font-family: var(--font-fraunces);
    font-size: 1.3rem;
    font-weight: 300;
    color: var(--feltoo-texto);
    margin: 0 0 10px 0;
    text-align: center;
}

.feltoo-crop-hint {
    color: var(--feltoo-texto-light);
    font-size: 0.9rem;
    margin: 0 0 20px 0;
    text-align: center;
}

.feltoo-crop-container {
    width: 100%;
    max-height: 50vh;
    overflow: hidden;
    background: var(--feltoo-fondo);
    border-radius: var(--feltoo-radius);
}

.feltoo-crop-container img {
    display: block;
    max-width: 100%;
}

.feltoo-crop-actions {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    justify-content: center;
}

.feltoo-crop-zoom {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    padding: 15px;
    background: var(--feltoo-fondo);
    border-radius: var(--feltoo-radius);
}

.feltoo-zoom-btn {
    background: var(--feltoo-white);
    border: 1px solid var(--feltoo-linea);
    border-radius: 8px;
    padding: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.feltoo-zoom-btn:hover {
    background: var(--feltoo-crema);
    border-color: var(--feltoo-verde-hover);
}

.feltoo-zoom-btn:active {
    transform: scale(0.95);
}

.feltoo-zoom-btn svg {
    stroke: var(--feltoo-texto);
}

.feltoo-zoom-slider {
    width: 150px;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: var(--feltoo-crema);
    border-radius: 3px;
    outline: none;
}

.feltoo-zoom-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background: var(--feltoo-verde);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.2s;
}

.feltoo-zoom-slider::-webkit-slider-thumb:hover {
    background: var(--feltoo-verde-oscuro);
}

.feltoo-zoom-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--feltoo-verde);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* ==========================================================================
   Back Button
   ========================================================================== */

.feltoo-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--feltoo-texto-light);
    font-size: 0.9rem;
    text-decoration: none;
    margin-bottom: 20px;
    cursor: pointer;
    transition: color 0.2s;
}

.feltoo-back-link:hover {
    color: var(--feltoo-verde);
}

.feltoo-back-link svg {
    width: 16px;
    height: 16px;
}

.feltoo-category-badge {
    display: inline-block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--feltoo-verde);
    margin-bottom: 10px;
}

/* ==========================================================================
   Image Change Button
   ========================================================================== */

.feltoo-image-preview-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.feltoo-image-change-btn {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: none;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--feltoo-texto);
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.feltoo-image-change-btn:hover {
    background: #fff;
    transform: translateX(-50%) scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.feltoo-image-change-btn svg {
    width: 16px;
    height: 16px;
    stroke: var(--feltoo-verde);
}

.feltoo-field-image.has-image .feltoo-image-change-btn {
    display: flex;
}

.feltoo-field-image.has-image .feltoo-image-preview-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.2s ease;
    pointer-events: none;
    border-radius: inherit;
}

.feltoo-field-image.has-image .feltoo-image-preview-wrapper:hover::after {
    background: rgba(0, 0, 0, 0.1);
}

.feltoo-field-image.has-image .feltoo-image-preview {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.feltoo-field-image.has-image .feltoo-image-label {
    display: none;
}

.feltoo-field-image.has-image .feltoo-image-preview-wrapper {
    display: block;
}

.feltoo-field-image:not(.has-image) .feltoo-image-preview-wrapper {
    display: none;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 960px) {
    .feltoo-main-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .feltoo-preview-column {
        position: relative;
        top: 0;
        order: -1;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .feltoo-preview-wrapper {
        max-width: 260px;
    }
    
    .feltoo-preview-hint,
    .feltoo-template-selector {
        max-width: 100%;
    }
    
    .feltoo-templates {
        justify-content: center;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .feltoo-category-card {
        grid-template-columns: 1fr;
    }
    
    .feltoo-category-image {
        height: 240px;
        border-radius: var(--feltoo-radius-lg) var(--feltoo-radius-lg) 0 0;
    }
    
    .feltoo-category-content {
        border-radius: 0 0 var(--feltoo-radius-lg) var(--feltoo-radius-lg);
        padding: 30px 35px;
    }
    
    .feltoo-steps-indicator {
        gap: 40px;
    }
}

@media (max-width: 600px) {
    .feltoo-app {
        padding: 25px 16px;
    }
    
    .feltoo-steps-indicator {
        gap: 20px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .feltoo-step-label {
        font-size: 0.6rem;
    }
    
    .feltoo-step-name {
        font-size: 0.7rem;
    }
    
    .feltoo-step-intro {
        margin-bottom: 35px;
    }
    
    .feltoo-step-intro h1 {
        font-size: 0.7rem;
        letter-spacing: 3px;
    }
    
    .feltoo-step-intro p {
        font-size: 1.05rem;
    }
    
    .feltoo-categories {
        gap: 25px;
    }
    
    .feltoo-category-card {
        grid-template-columns: 1fr;
    }
    
    .feltoo-category-image {
        height: 200px;
    }
    
    .feltoo-category-content {
        padding: 25px 20px;
    }
    
    .feltoo-category-name {
        font-size: 1.25rem;
    }
    
    .feltoo-category-desc {
        font-size: 0.9rem;
        margin-bottom: 22px;
    }
    
    .feltoo-category-btn {
        padding: 12px 30px;
        font-size: 0.85rem;
        width: 100%;
        justify-content: center;
    }
    
    .feltoo-preview-wrapper {
        max-width: 220px;
    }
    
    .feltoo-form {
        gap: 18px;
    }
    
    .feltoo-images-row {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
    
    .feltoo-field-row {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    
    .feltoo-templates {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .feltoo-btn-primary,
    .feltoo-btn-secondary {
        padding: 14px 30px;
        font-size: 0.95rem;
        width: 100%;
    }
    
    .feltoo-submit-buttons {
        flex-direction: column;
        width: 100%;
    }

    .feltoo-submit-main {
        width: 100%;
    }
    
    .feltoo-crop-modal-content {
        padding: 20px;
        margin: 10px;
    }
    
    .feltoo-crop-title {
        font-size: 1.1rem;
    }
    
    .feltoo-crop-actions {
        flex-direction: column;
    }
    
    .feltoo-crop-actions button {
        width: 100%;
    }
    
    .feltoo-image-change-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .feltoo-image-change-btn span {
        display: none;
    }
    
    .feltoo-image-change-btn svg {
        width: 20px;
        height: 20px;
    }
}

/* ============================================
   FELTOO REPEATER FIELDS
   Afegir al final de feltoo-styles.css
   ============================================ */

/* Repeater Container */
.feltoo-repeater {
    margin: 1.5rem 0;
    padding: 1.25rem;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    background: #fafafa;
}

.feltoo-repeater-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e5e5e5;
}

.feltoo-repeater-title {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.feltoo-repeater-count {
    font-size: 0.8rem;
    color: #888;
    background: #fff;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    border: 1px solid #e5e5e5;
}

/* Items Container */
.feltoo-repeater-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Individual Item */
.feltoo-repeater-item {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 10px;
    padding: 1rem;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.feltoo-repeater-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-color: #d0d0d0;
}

.feltoo-repeater-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px dashed #e5e5e5;
}

.feltoo-repeater-item-label {
    font-weight: 600;
    font-size: 0.9rem;
    color: #555;
}

/* Remove Button */
.feltoo-repeater-remove {
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    color: #bbb;
    border-radius: 6px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feltoo-repeater-remove:hover {
    color: #e53935;
    background: rgba(229, 57, 53, 0.08);
}

.feltoo-repeater-remove.hidden {
    display: none;
}

/* Item Fields */
.feltoo-repeater-item-fields {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 1rem;
    align-items: start;
}

.feltoo-repeater-item-fields .feltoo-field {
    margin-bottom: 0;
}

.feltoo-repeater-item-fields .feltoo-field-image {
    grid-row: 1 / span 3;
}

/* Repeater Image Field */
.feltoo-repeater-image {
    width: 120px;
}

.feltoo-repeater-image .feltoo-image-label {
    width: 100%;
    height: 180px;
    min-height: auto;
}

.feltoo-repeater-image .feltoo-image-preview-wrapper {
    width: 100%;
    height: 180px;
}

.feltoo-repeater-image .feltoo-image-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.feltoo-repeater-image .feltoo-image-change-btn {
    padding: 4px 8px;
    font-size: 0.7rem;
}

.feltoo-repeater-image .feltoo-image-change-btn svg {
    width: 12px;
    height: 12px;
}

/* Add Button */
.feltoo-repeater-add {
    width: 100%;
    padding: 0.875rem 1rem;
    margin-top: 1rem;
    border: 2px dashed #ccc;
    border-radius: 10px;
    background: transparent;
    color: #666;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.feltoo-repeater-add:hover:not(.disabled) {
    border-color: #333;
    color: #333;
    background: rgba(0, 0, 0, 0.02);
}

.feltoo-repeater-add.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Mobile Responsive */
@media (max-width: 600px) {
    .feltoo-repeater {
        padding: 1rem;
    }
    
    .feltoo-repeater-item {
        padding: 0.875rem;
    }
    
    .feltoo-repeater-item-fields {
        grid-template-columns: 1fr;
    }
    
    .feltoo-repeater-item-fields .feltoo-field-image {
        grid-row: auto;
        justify-self: center;
        margin-bottom: 0.5rem;
    }
    
    .feltoo-repeater-image {
        width: 100px;
    }
    
    .feltoo-repeater-image .feltoo-image-label,
    .feltoo-repeater-image .feltoo-image-preview-wrapper {
        height: 150px;
    }
}

/* Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feltoo-repeater-item {
    animation: fadeInUp 0.3s ease-out;
}

/* ============================================
   FELTOO - Color Select & Toggle Styles
   Afegir al final de feltoo-styles.css
   ============================================ */

/* ============ COLOR SELECT ============ */
.feltoo-field-color-select {
    margin-bottom: 1.5rem;
}

.feltoo-field-color-select label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 500;
    color: #333;
}

.feltoo-color-options {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.feltoo-color-option {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.feltoo-color-option:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.feltoo-color-option.active {
    border-color: #333;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #333;
}

.feltoo-color-option.active::after {
    content: '✓';
    color: #fff;
    font-size: 18px;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.feltoo-color-name {
    position: absolute;
    bottom: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: #666;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.feltoo-color-option:hover .feltoo-color-name,
.feltoo-color-option.active .feltoo-color-name {
    opacity: 1;
}

/* ============ TOGGLE SWITCH ============ */
.feltoo-field-toggle {
    margin-bottom: 1.5rem;
}

.feltoo-toggle-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 0.75rem 0;
}

.feltoo-toggle-text {
    font-weight: 500;
    color: #333;
}

.feltoo-toggle-switch {
    position: relative;
    width: 52px;
    height: 28px;
    flex-shrink: 0;
}

.feltoo-toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.feltoo-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 28px;
}

.feltoo-toggle-slider::before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.feltoo-toggle-switch input:checked + .feltoo-toggle-slider {
    background-color: #4A5A42;
}

.feltoo-toggle-switch input:checked + .feltoo-toggle-slider::before {
    transform: translateX(24px);
}

.feltoo-toggle-switch input:focus + .feltoo-toggle-slider {
    box-shadow: 0 0 0 2px rgba(74, 90, 66, 0.3);
}

/* ============ FIELD HINT ============ */
.feltoo-field-hint {
    display: block;
    margin-top: 0.5rem;
    font-size: 12px;
    color: #888;
    font-style: italic;
}

/* ============================================
   FELTOO - Color Select & Toggle Styles
   Afegir al final de feltoo-styles.css
   ============================================ */

/* ============ COLOR SELECT ============ */
.feltoo-field-color-select {
    margin-bottom: 1.5rem;
}

.feltoo-field-color-select label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 500;
    color: #333;
}

.feltoo-color-options {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.feltoo-color-option {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.feltoo-color-option:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.feltoo-color-option.active {
    border-color: #333;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #333;
}

.feltoo-color-option.active::after {
    content: '✓';
    color: #fff;
    font-size: 18px;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.feltoo-color-name {
    position: absolute;
    bottom: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: #666;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.feltoo-color-option:hover .feltoo-color-name,
.feltoo-color-option.active .feltoo-color-name {
    opacity: 1;
}

/* ============ SYMBOL SELECT ============ */
.feltoo-field-symbol-select {
    margin-bottom: 1.5rem;
}

.feltoo-field-symbol-select label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 500;
    color: #333;
}

.feltoo-symbol-options {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    padding-bottom: 1.25rem; /* room for the name under the active button */
}

.feltoo-symbol-option {
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: 50%;
    border: 3px solid transparent;
    background: #fff;
    color: #383E2F;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.feltoo-symbol-option svg {
    display: block;
}

.feltoo-symbol-option:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.feltoo-symbol-option.active {
    border-color: #333;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #333;
}

.feltoo-symbol-name {
    position: absolute;
    bottom: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: #666;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}

.feltoo-symbol-option:hover .feltoo-symbol-name,
.feltoo-symbol-option.active .feltoo-symbol-name {
    opacity: 1;
}

/* ============ TOGGLE SWITCH ============ */
.feltoo-field-toggle {
    margin-bottom: 1.5rem;
}

.feltoo-toggle-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 0.75rem 0;
}

.feltoo-toggle-text {
    font-weight: 500;
    color: #333;
}

.feltoo-toggle-switch {
    position: relative;
    width: 52px;
    height: 28px;
    flex-shrink: 0;
}

.feltoo-toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.feltoo-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 28px;
}

.feltoo-toggle-slider::before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.feltoo-toggle-switch input:checked + .feltoo-toggle-slider {
    background-color: #4A5A42;
}

.feltoo-toggle-switch input:checked + .feltoo-toggle-slider::before {
    transform: translateX(24px);
}

.feltoo-toggle-switch input:focus + .feltoo-toggle-slider {
    box-shadow: 0 0 0 2px rgba(74, 90, 66, 0.3);
}

/* ============ FIELD HINT ============ */
.feltoo-field-hint {
    display: block;
    margin-top: 0.5rem;
    font-size: 12px;
    color: #888;
    font-style: italic;
}

/* ============ PARTNER PREVIEW BANNER ============ */
/* El banner és position:fixed — empenyem el contingut cap avall */
body:has(.partner-preview-banner) .feltoo-page { padding-top: 44px !important; }
body:has(.partner-preview-banner) .feltoo-app  { padding-top: 84px !important; }
