/* Container Utama */
.tfoto {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 1rem;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #1f2937;
}

/* Hero Section */
.tfoto__hero {
    text-align: center;
    margin-bottom: 2rem;
}

.tfoto__title {
    font-size: 2.25rem;
    font-weight: 800;
    color: #111827;
    margin-bottom: 0.75rem;
}

.tfoto__title span {
    color: #2563eb;
    display: block;
}

.tfoto__subtitle {
    font-size: 1rem;
    color: #4b5563;
    max-width: 680px;
    margin: 0 auto 1.25rem auto;
    line-height: 1.6;
}

.tfoto__features {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: #4b5563;
}

.tfoto__feature-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: #16a34a;
    border-radius: 50%;
    margin-right: 6px;
}

/* CARD BOX STYLING */
.tfoto__card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1.25rem;
    padding: 2rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.04);
    margin-bottom: 2rem;
}

/* Inner Dropzone Area Upload (Garis Putus-Putus) */
.tfoto__upload {
    border: 2px dashed #3b82f6;
    border-radius: 1rem;
    background-color: #f8fafc;
    padding: 3.5rem 2rem;
    text-align: center;
    transition: all 0.25s ease;
    cursor: pointer;
    user-select: none;
    outline: none;
}

.tfoto__upload:hover,
.tfoto__upload:focus,
.tfoto__upload.is-dragover {
    border-color: #1d4ed8;
    background-color: #eff6ff;
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.08);
}

.tfoto__file-input {
    display: none;
}

.tfoto__upload-icon {
    width: 64px;
    height: 64px;
    background-color: #e0e7ff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem auto;
    color: #2563eb;
    pointer-events: none;
}

.tfoto__upload-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 0.4rem;
    color: #0f172a;
    pointer-events: none;
}

.tfoto__upload-description {
    color: #64748b;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    pointer-events: none;
}

.tfoto__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 0.6rem;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
}

.tfoto__button--primary {
    background-color: #2563eb;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
    pointer-events: none; /* Klik diteruskan ke card/upload container */
}

.tfoto__button--primary:hover {
    background-color: #1d4ed8;
}

.tfoto__upload-hint {
    margin-top: 1.25rem;
    font-size: 0.85rem;
    color: #94a3b8;
    pointer-events: none;
}

.tfoto__privacy {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: #059669;
    background-color: #ecfdf5;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    display: inline-block;
    pointer-events: none;
}

/* Editor Grid & Canvas */
.tfoto__section-kicker {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #2563eb;
    text-transform: uppercase;
    display: block;
    margin-bottom: 0.25rem;
}

.tfoto__section-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 1rem;
}

.tfoto__editor-grid {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .tfoto__editor-grid {
        grid-template-columns: 1fr;
    }
}

.tfoto__settings {
    background: #f8fafc;
    padding: 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid #e2e8f0;
}

.tfoto__control {
    margin-bottom: 1.25rem;
}

.tfoto__label-row {
    display: flex;
    justify-content: space-between;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.tfoto__control input[type="range"] {
    width: 100%;
    accent-color: #2563eb;
}

.tfoto__range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 0.25rem;
}

.tfoto__control-help {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.35rem;
}

.tfoto__canvas-wrap {
    width: 100%;
    background: #0f172a;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 320px;
    max-height: 500px;
    overflow: hidden;
}

.tfoto__canvas-wrap canvas {
    max-width: 100%;
    height: auto;
}

.tfoto__file-info {
    margin-top: 0.75rem;
    font-size: 0.9rem;
    color: #475569;
}

/* Steps Grid */
.tfoto__steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (max-width: 640px) {
    .tfoto__steps {
        grid-template-columns: 1fr;
    }
}

.tfoto__step {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.tfoto__step-number {
    font-weight: 800;
    color: #2563eb;
    font-size: 1.1rem;
}

/* Card Panduan & FAQ */
.tfoto__card--guide h2, .tfoto__card--faq h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 1rem;
}

.tfoto__article-content {
    color: #374151;
    line-height: 1.7;
    font-size: 0.95rem;
}

.tfoto__article-content ol {
    margin-left: 1.25rem;
    margin-bottom: 1rem;
}

.tfoto__article-content li {
    margin-bottom: 0.5rem;
}

.tfoto__divider {
    border: 0;
    border-top: 1px dashed #cbd5e1;
    margin: 1.5rem 0;
}

/* FAQ Accordion (+ dan ×) */
.tfoto-faq__list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tfoto-faq__item {
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    overflow: hidden;
}

.tfoto-faq__question {
    width: 100%;
    background: #f8fafc;
    padding: 1rem 1.25rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #1f2937;
}

.tfoto-faq__question::after {
    content: "+";
    font-size: 1.3rem;
    font-weight: 700;
    color: #2563eb;
}

.tfoto-faq__item.is-open .tfoto-faq__question::after {
    content: "×";
    font-size: 1.5rem;
}

.tfoto-faq__answer {
    padding: 0 1.25rem;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    color: #4b5563;
    line-height: 1.6;
}

.tfoto-faq__item.is-open .tfoto-faq__answer {
    padding: 1rem 1.25rem;
    max-height: 300px;
}

/* Styling Card Panduan (Meniru Referensi Gambar) */
.tfoto__card--guide {
    padding: 2.25rem;
}

.tfoto__guide-heading {
    font-size: 1.35rem;
    font-weight: 800;
    color: #111827;
    margin-bottom: 0.5rem;
}

.tfoto__guide-sub {
    font-size: 0.95rem;
    color: #4b5563;
    margin-bottom: 1.75rem;
}

.tfoto__guide-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tfoto__guide-step-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    transition: border-color 0.2s;
}

.tfoto__guide-step-item:hover {
    border-color: #cbd5e1;
}

.tfoto__step-badge {
    width: 32px;
    height: 32px;
    background-color: #2563eb;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(37, 99, 235, 0.3);
}

.tfoto__step-text {
    font-size: 0.95rem;
    color: #334155;
    line-height: 1.5;
}

/* CONTAINER EDITOR CARD */
.tfoto__editor {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1.25rem;
    padding: 2rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
}

.tfoto__section-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.tfoto__editor-grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 2rem;
}

@media (max-width: 768px) {
    .tfoto__editor-grid {
        grid-template-columns: 1fr;
    }
}

/* PANEL PENGATURAN (KIRI) */
.tfoto__settings {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    padding: 1.5rem;
}

.tfoto__panel-heading {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.tfoto__panel-icon {
    font-size: 1.25rem;
    color: #2563eb;
}

.tfoto__panel-heading h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
}

.tfoto__panel-heading p {
    margin: 0;
    font-size: 0.8rem;
    color: #64748b;
}

.tfoto__control {
    margin-bottom: 1.25rem;
}

.tfoto__label-row {
    display: flex;
    justify-content: space-between;
    font-weight: 600;
    font-size: 0.9rem;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.tfoto__control input[type="range"] {
    width: 100%;
    accent-color: #2563eb;
    cursor: pointer;
}

.tfoto__range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #94a3b8;
    margin-top: 0.25rem;
}

.tfoto__control-help {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.35rem;
    line-height: 1.4;
}

/* AREA PRATINJAU CANVAS (KANAN) - KEREN & ELEGAN */
.tfoto__preview-panel {
    display: flex;
    flex-direction: column;
}

.tfoto__preview-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.tfoto__preview-top h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: #0f172a;
}

/* BACKGROUND KEREN: MOTIF CHECKERBOARD / TRANSPARAN BERSIH */
.tfoto__canvas-wrap {
    width: 100%;
    min-height: 360px;
    max-height: 520px;
    border-radius: 1rem;
    border: 1px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;

    /* Background Motif Papan Catur Transparan yang Sangat Keren */
    background-color: #f8fafc;
    background-image: 
        linear-gradient(45deg, #e2e8f0 25%, transparent 25%), 
        linear-gradient(-45deg, #e2e8f0 25%, transparent 25%), 
        linear-gradient(45deg, transparent 75%, #e2e8f0 75%), 
        linear-gradient(-45deg, transparent 75%, #e2e8f0 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.03);
}

.tfoto__canvas-wrap canvas {
    max-width: 100%;
    max-height: 500px;
    height: auto;
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* TOMBOL LIHAT FOTO ASLI - BISA TOGGLE CLICK & PRESS */
.tfoto__button--toggle {
    background-color: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tfoto__button--toggle:hover {
    background-color: #e2e8f0;
    color: #0f172a;
}

/* Status saat aktif melihat foto asli */
.tfoto__button--toggle.is-active {
    background-color: #2563eb !important;
    color: #ffffff !important;
    border-color: #1d4ed8 !important;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.tfoto__file-info {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: #475569;
    font-weight: 500;
}

.tfoto__preview-tip {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 0.4rem;
}