/* ==========================================================
   YouTube Title Extractor
   Design system matches the existing YouTube Title Generator /
   Description Extractor: same container, colors, radius, shadow,
   cards, buttons.
   ========================================================== */

.yte-wrap,
.yte-wrap *{
    box-sizing:border-box;
    font-family:Arial,sans-serif;
}
.yte-wrap{
    max-width:1200px;
    width:100%;
    margin:30px auto;
    background:#EEF5FF;
    padding:24px;
    border-radius:12px;
    box-shadow:0 10px 30px rgba(0,0,0,.1);
}
.yte-wrap h2{
    text-align:center;
    margin:0 0 6px;
    color:#1a3b6b;
}
.yte-wrap p{
    text-align:center;
    margin-bottom:25px;
    color:#666;
}
.yte-wrap label{
    display:block;
    font-weight:bold;
    margin:15px 0 6px;
}
.yte-wrap input{
    width:100%;
    padding:12px;
    border:1px solid #ddd;
    border-radius:8px;
    font-size:15px;
    background:#fff;
}
.yte-wrap input:focus{
    outline:none;
    border-color:#e62117;
    box-shadow:0 0 0 3px rgba(230,33,23,.12);
}
.yte-example{
    text-align:left !important;
    font-size:12px;
    color:#999 !important;
    margin:6px 0 0 !important;
}

/* Primary red action button */
.yte-btn{
    display:inline-block;
    padding:14px 24px;
    background:#e62117;
    color:#fff;
    border:none;
    border-radius:8px;
    font-size:16px;
    font-weight:bold;
    cursor:pointer;
    margin-top:20px;
    transition:background .15s ease, transform .1s ease;
}
.yte-btn:hover{ background:#c4120f; }
.yte-btn:active{ transform:scale(.98); }
.yte-btn:disabled{
    opacity:.6;
    cursor:not-allowed;
    transform:none;
}

/* Loader */
.yte-loader{
    display:none;
    align-items:center;
    gap:10px;
    margin-top:20px;
    font-weight:bold;
    color:#1a3b6b;
}
.yte-spinner{
    width:18px;
    height:18px;
    border:3px solid #cdddf5;
    border-top-color:#1a3b6b;
    border-radius:50%;
    display:inline-block;
    animation:yte-spin .8s linear infinite;
}
@keyframes yte-spin{
    to{ transform:rotate(360deg); }
}

/* Alerts */
.yte-alert{
    display:none;
    margin-top:20px;
    padding:14px 16px;
    border-radius:10px;
    font-weight:bold;
    font-size:14px;
}
.yte-alert-error{
    background:#fdeceb;
    border:1px solid #f3b7b1;
    color:#c4120f;
}
.yte-alert-success{
    background:#e9f8ec;
    border:1px solid #a9dfb4;
    color:#218838;
}

/* Result section */
.yte-result{
    margin-top:25px;
    display:none;
    animation:yte-fade-in .25s ease;
}
@keyframes yte-fade-in{
    from{ opacity:0; transform:translateY(6px); }
    to{ opacity:1; transform:translateY(0); }
}

.yte-video-card{
    background:#fff;
    border:1px solid #ddd;
    border-radius:10px;
    padding:16px;
    margin-bottom:20px;
    display:flex;
    gap:16px;
    align-items:flex-start;
    flex-wrap:wrap;
}
.yte-thumb{
    width:280px;
    max-width:100%;
    border-radius:8px;
    display:block;
    flex-shrink:0;
    background:#eee;
}
.yte-video-meta{
    flex:1;
    min-width:220px;
}
.yte-video-title{
    font-size:17px;
    font-weight:bold;
    color:#1a3b6b;
    line-height:1.4;
    margin-bottom:6px;
}
.yte-video-sub{
    font-size:13px;
    color:#888;
    margin-bottom:12px;
}
.yte-stats-row{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
}
.yte-stat-pill{
    background:#EEF5FF;
    color:#1a3b6b;
    border:1px solid #cdddf5;
    border-radius:20px;
    padding:5px 12px;
    font-size:12px;
    font-weight:normal;
}

/* Exact title box */
.yte-title-box{
    background:#fff;
    border:1px solid #ddd;
    border-radius:10px;
    padding:16px;
    white-space:pre-wrap;
    word-wrap:break-word;
    line-height:1.6;
    font-size:16px;
    font-weight:bold;
    color:#1a3b6b;
}

/* Action buttons row */
.yte-actions{
    display:flex;
    gap:12px;
    flex-wrap:wrap;
    margin-top:16px;
}
.yte-action-btn{
    border:none;
    padding:12px 20px;
    border-radius:8px;
    cursor:pointer;
    font-weight:bold;
    font-size:14px;
    color:#fff;
    transition:background .2s ease;
}
.yte-copy-btn{ background:#28a745; }
.yte-copy-btn:hover{ background:#218838; }
.yte-copy-btn.copied{ background:#1a7a37; }

.yte-download-btn{ background:#1a3b6b; }
.yte-download-btn:hover{ background:#12294d; }

.yte-clear-btn{ background:#888; }
.yte-clear-btn:hover{ background:#666; }

/* Responsive */
@media (max-width:640px){
    .yte-video-card{ flex-direction:column; }
    .yte-thumb{ width:100%; }
    .yte-actions{ flex-direction:column; }
    .yte-action-btn{ width:100%; text-align:center; }
}
