/**
 * Project: DailyWebUtils - SaaS Tool UI
 * Version: 2.0 (Bulletproof Responsive)
 * Author: Gemini AI Collaboration
 */

/* 1. Global Variables & Root Settings
   -------------------------------------------------- */
:root {
    --dw-primary: #2563eb;       /* Brand Blue */
    --dw-primary-soft: #eff6ff;  /* Badge/Light Blue */
    --dw-bg: #f8fafc;            /* Body Background */
    --dw-card: #ffffff;          /* Card Background */
    --dw-border: #e2e8f0;        /* Default Border */
    --dw-text: #0f172a;          /* Main Heading Color */
    --dw-text-mut: #64748b;      /* Muted Subheadings */
    --dw-danger: #ef4444;        /* Reset/Red Button */
    --dw-font: 'Inter', system-ui, sans-serif;
}

/* 2. Main Tool Box Layout
   -------------------------------------------------- */
.dw-tool-card-box {
    max-width: 1000px;
    width: 100%;
    margin: 40px auto;
    background: var(--dw-card);
    border-radius: 24px;
    padding: 45px;
    border: 1px solid var(--dw-border);
    font-family: var(--dw-font);
    box-sizing: border-box;
    overflow: hidden;
    
    /* Premium Double Shadow Effect */
    box-shadow: 0 20px 40px rgba(0,0,0,0.06), 0 40px 90px rgba(0,0,0,0.08);
    transition: all .35s cubic-bezier(0.4, 0, 0.2, 1);
    animation: dwFadeIn 0.6s ease-out;
}

/* 3. Interactions (Hover Effect)
   -------------------------------------------------- */
.dw-tool-card-box:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px rgba(0,0,0,0.12);
    border-color: var(--dw-primary);
}

@keyframes dwFadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 4. Typography & Header Section
   -------------------------------------------------- */
.dw-tool-info { text-align: center; margin-bottom: 40px; }

.dw-badge { 
    display: inline-flex; 
    align-items: center;
    gap: 8px;
    background: var(--dw-primary-soft); 
    color: var(--dw-primary); 
    padding: 6px 16px; 
    border-radius: 50px; 
    font-size: 12px; 
    font-weight: 700; 
    text-transform: uppercase; 
    margin-bottom: 12px; 
}

.dw-tool-info h2 { 
    font-size: clamp(24px, 5vw, 34px); 
    font-weight: 800; 
    color: var(--dw-text); 
    margin: 0; 
    letter-spacing: -1.5px; 
}

.dw-tool-info p.dw-lead-text {
    font-size: 18px;
    font-weight: 400; /* Professional Regular weight */
    color: var(--dw-text-mut);
    margin-top: 10px;
}

/* 5. Form Elements (Labels & Textareas)
   -------------------------------------------------- */
.dw-label-row { display: flex; justify-content: space-between; margin-bottom: 10px; align-items: center; }
.dw-label { font-size: 12px; font-weight: 700; color: var(--dw-text-mut); text-transform: uppercase; letter-spacing: 0.5px; }
.dw-pill { background: var(--dw-primary); color: #fff; padding: 2px 12px; border-radius: 50px; font-size: 11px; font-weight: 600; }

.dw-input-area {
    width: 100%; height: 160px; padding: 20px; border-radius: 16px;
    border: 2px solid var(--dw-border); background: var(--dw-bg);
    font-size: 16px; transition: 0.3s; outline: none; resize: vertical; box-sizing: border-box;
}

.dw-input-area:focus { 
    border-color: var(--dw-primary); 
    background: #fff; 
    box-shadow: 0 0 0 4px rgba(37,99,235,0.1); 
}

.dw-res-bg { background: #f1f5f9 !important; border-style: dashed; }

/* 6. Control Bar & Dropdown Fix
   -------------------------------------------------- */
.dw-control-bar {
    display: flex; gap: 15px; background: var(--dw-bg); padding: 20px;
    border-radius: 20px; margin: 30px 0; border: 1px solid var(--dw-border);
    align-items: center;
}

.dw-select-wrapper { flex: 1; }

.dw-custom-select { 
    width: 100%;
    padding: 12px 15px; 
    border-radius: 12px; 
    border: 2px solid var(--dw-border); 
    font-weight: 600; 
    font-size: 15px;
    color: var(--dw-text);
    background-color: #fff;
    outline: none; 
    transition: 0.3s;
    line-height: 1.5; 
    height: auto; 
    appearance: none;
    /* Custom SVG Arrow */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 18px;
    padding-right: 40px;
}

/* 7. Buttons Style
   -------------------------------------------------- */
.dw-btn-group { display: flex; gap: 10px; }

.dw-btn-main { 
    padding: 12px 25px; 
    border-radius: 12px; 
    border: none; 
    font-weight: 700; 
    cursor: pointer; 
    transition: 0.2s; 
    display: flex; 
    align-items: center; 
    gap: 8px; 
    white-space: nowrap; 
}

.dw-copy { background: var(--dw-primary); color: #fff; }
.dw-copy:hover { background: #1d4ed8; transform: translateY(-1px); }

.dw-reset { background: #fee2e2; color: var(--dw-danger); }
.dw-reset:hover { background: #fecaca; }

/* 8. Bulletproof Media Queries (Responsive)
   -------------------------------------------------- */

/* Tablet & Mobile (Auto Stack Controls) */
@media (max-width: 900px) {
    .dw-tool-card-box { padding: 30px 20px; margin: 20px auto; }
    .dw-control-bar { flex-direction: column; align-items: stretch; gap: 20px; }
    .dw-btn-group { width: 100%; }
    .dw-btn-main { flex: 1; justify-content: center; }
}

/* Mobile Phones (Small Spacing) */
@media (max-width: 600px) {
    .dw-tool-card-box { border-radius: 16px; padding: 25px 15px; }
    .dw-tool-info h2 { font-size: 26px; }
    .dw-input-area { height: 140px; font-size: 15px; }
}