:root {
    --primary: #4F46E5;
    --primary-light: #818CF8;
    --secondary: #EC4899;
    --bg-dark: #0F172A;
    --panel-bg: rgba(30, 41, 59, 0.7);
    --text-main: #F8FAFC;
    --text-muted: #94A3B8;
    --success: #10B981;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Background gradient blobs */
.background-decor {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.6;
    animation: float 20s infinite alternate linear;
}

.blob1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--primary) 0%, rgba(79,70,229,0) 70%);
    top: -100px;
    left: -100px;
}

.blob2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--secondary) 0%, rgba(236,72,153,0) 70%);
    bottom: -100px;
    right: -100px;
    animation-delay: -10s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(100px, 50px) scale(1.1); }
}

/* App Container */
.app-container {
    width: 90%;
    max-width: 480px;
    padding: 2.5rem 2rem;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    background: var(--panel-bg);
    display: flex;
    flex-direction: column;
    gap: 2rem;
    position: relative;
    z-index: 1;
}

/* Header */
header {
    text-align: center;
}

.header-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.header-logo i {
    font-size: 2rem;
    color: var(--primary-light);
}

header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    background: linear-gradient(to right, #fff, #a5b4fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 300;
}

/* Main Interaction */
.main-interaction {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.mic-container {
    position: relative;
    width: 120px;
    height: 120px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.mic-container:hover {
    transform: scale(1.05);
}

.mic-container:active {
    transform: scale(0.95);
}

.pulse-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--primary-light);
    opacity: 0;
    box-sizing: border-box;
}

.mic-button {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary), #312e81);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    color: white;
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.5);
    z-index: 2;
    transition: all 0.3s ease;
}

/* Recording State */
.recording .pulse-ring {
    animation: pulsate 1.5s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
    border-color: var(--secondary);
}

.recording .mic-button {
    background: linear-gradient(135deg, var(--secondary), #9d174d);
    box-shadow: 0 10px 25px rgba(236, 72, 153, 0.5);
}

@keyframes pulsate {
    0% { transform: scale(0.8); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: scale(1.4); opacity: 0; }
}

.status-indicator {
    text-align: center;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

/* Audio waves animation */
#listening-waves {
    display: flex;
    gap: 4px;
    height: 20px;
    align-items: center;
}

.wave {
    width: 4px;
    height: 10px;
    background-color: var(--secondary);
    border-radius: 2px;
    animation: wave-anim 1s infinite alternate ease-in-out;
}

.wave:nth-child(2) { animation-delay: 0.2s; }
.wave:nth-child(3) { animation-delay: 0.4s; }
.wave:nth-child(4) { animation-delay: 0.6s; }

@keyframes wave-anim {
    0% { height: 6px; }
    100% { height: 24px; }
}

.hidden {
    display: none !important;
}

/* Results Box */
.results-container {
    background: rgba(15, 23, 42, 0.5);
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    animation: slideUp 0.4s ease forwards;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary-light);
    margin-bottom: 0.25rem;
    display: block;
    font-weight: 600;
}

.transcript-box p {
    font-style: italic;
    color: var(--text-muted);
    line-height: 1.5;
}

.answer-box p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: white;
}

.audio-player {
    margin-top: 10px;
}
.audio-player audio {
    width: 100%;
    height: 36px;
    outline: none;
    border-radius: 12px;
}

.meta-info {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 0.75rem;
    color: #64748B;
    display: flex;
    justify-content: space-between;
}

/* Hints */
.hint-section {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 1.25rem;
    font-size: 0.9rem;
}

.hint-section p {
    color: var(--primary-light);
    margin-bottom: 0.75rem;
    font-weight: 500;
}

.hint-section ul {
    list-style-type: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.hint-section li {
    color: var(--text-muted);
    position: relative;
    padding-left: 1.25rem;
}

.hint-section li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--primary);
}

#processing-loader {
    color: var(--primary-light);
    font-weight: 500;
    display: flex;
    gap: 8px;
    align-items: center;
}

/* Course Cards styling */
.course-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 5px;
}
.course-list::-webkit-scrollbar {
    width: 6px;
}
.course-list::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.1);
}
.course-list::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}
.course-card {
    background-color: #111116;
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    border-top: 4px solid var(--primary-light);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    position: relative;
    border: 1px solid rgba(255,255,255,0.05);
}
.card-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
}
.card-badges {
    display: flex;
    gap: 0.5rem;
}
.badge-type {
    background-color: rgba(79, 70, 229, 0.15);
    color: var(--primary-light);
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    border: 1px solid rgba(79, 70, 229, 0.3);
}
.badge-location {
    background-color: transparent;
    color: #e2e8f0;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    border: 1px solid #f59e0b;
}
.badge-no {
    color: #94a3b8;
    background: rgba(0,0,0,0.4);
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
}
.card-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: white;
}
.card-details-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: #94a3b8;
}
.card-details-list li i {
    width: 16px;
    margin-right: 0.4rem;
}
.card-quota {
    color: var(--primary-light);
    font-weight: 500;
}

/* Developer Notice */
.developer-notice {
    text-align: center;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 1.5rem;
    padding: 0 20px;
    line-height: 1.5;
    max-width: 500px;
    margin-bottom: 2rem;
    z-index: 10;
    position: relative;
}
.developer-notice strong {
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
}

 / *   C o u r s e   C a r d s   s t y l i n g   * / 
 . c o u r s e - l i s t   { 
         d i s p l a y :   f l e x ; 
         f l e x - d i r e c t i o n :   c o l u m n ; 
         g a p :   1 r e m ; 
         m a r g i n - t o p :   1 r e m ; 
         m a x - h e i g h t :   4 0 0 p x ; 
         o v e r f l o w - y :   a u t o ; 
         p a d d i n g - r i g h t :   5 p x ; 
 } 
 . c o u r s e - l i s t : : - w e b k i t - s c r o l l b a r   { 
         w i d t h :   6 p x ; 
 } 
 . c o u r s e - l i s t : : - w e b k i t - s c r o l l b a r - t r a c k   { 
         b a c k g r o u n d :   r g b a ( 0 , 0 , 0 , 0 . 1 ) ; 
 } 
 . c o u r s e - l i s t : : - w e b k i t - s c r o l l b a r - t h u m b   { 
         b a c k g r o u n d :   v a r ( - - p r i m a r y ) ; 
         b o r d e r - r a d i u s :   4 p x ; 
 } 
 . c o u r s e - c a r d   { 
         b a c k g r o u n d - c o l o r :   # 1 1 1 1 1 6 ; 
         b o r d e r - r a d i u s :   1 2 p x ; 
         p a d d i n g :   1 . 2 5 r e m ; 
         b o x - s h a d o w :   0   4 p x   6 p x   r g b a ( 0 , 0 , 0 , 0 . 2 ) ; 
         b o r d e r - t o p :   4 p x   s o l i d   v a r ( - - p r i m a r y - l i g h t ) ; 
         d i s p l a y :   f l e x ; 
         f l e x - d i r e c t i o n :   c o l u m n ; 
         g a p :   0 . 7 5 r e m ; 
         p o s i t i o n :   r e l a t i v e ; 
 } 
 . c a r d - h e a d e r - r o w   { 
         d i s p l a y :   f l e x ; 
         j u s t i f y - c o n t e n t :   s p a c e - b e t w e e n ; 
         a l i g n - i t e m s :   c e n t e r ; 
         f o n t - s i z e :   0 . 7 5 r e m ; 
 } 
 . c a r d - b a d g e s   { 
         d i s p l a y :   f l e x ; 
         g a p :   0 . 5 r e m ; 
 } 
 . b a d g e - t y p e   { 
         b a c k g r o u n d - c o l o r :   r g b a ( 7 9 ,   7 0 ,   2 2 9 ,   0 . 1 5 ) ; 
         c o l o r :   v a r ( - - p r i m a r y - l i g h t ) ; 
         p a d d i n g :   0 . 2 r e m   0 . 6 r e m ; 
         b o r d e r - r a d i u s :   1 2 p x ; 
         b o r d e r :   1 p x   s o l i d   r g b a ( 7 9 ,   7 0 ,   2 2 9 ,   0 . 3 ) ; 
 } 
 . b a d g e - l o c a t i o n   { 
         b a c k g r o u n d - c o l o r :   t r a n s p a r e n t ; 
         c o l o r :   # e 2 e 8 f 0 ; 
         p a d d i n g :   0 . 2 r e m   0 . 6 r e m ; 
         b o r d e r - r a d i u s :   1 2 p x ; 
         b o r d e r :   1 p x   s o l i d   # f 5 9 e 0 b ; 
 } 
 . b a d g e - n o   { 
         c o l o r :   # 9 4 a 3 b 8 ; 
         b a c k g r o u n d :   r g b a ( 0 , 0 , 0 , 0 . 4 ) ; 
         p a d d i n g :   0 . 2 r e m   0 . 6 r e m ; 
         b o r d e r - r a d i u s :   6 p x ; 
 } 
 . c a r d - t i t l e   { 
         f o n t - w e i g h t :   6 0 0 ; 
         f o n t - s i z e :   1 . 1 r e m ; 
         c o l o r :   w h i t e ; 
 } 
 . c a r d - d e t a i l s - l i s t   { 
         l i s t - s t y l e :   n o n e ; 
         d i s p l a y :   f l e x ; 
         f l e x - d i r e c t i o n :   c o l u m n ; 
         g a p :   0 . 4 r e m ; 
         f o n t - s i z e :   0 . 8 5 r e m ; 
         c o l o r :   # 9 4 a 3 b 8 ; 
 } 
 . c a r d - d e t a i l s - l i s t   l i   i   { 
         w i d t h :   1 6 p x ; 
         m a r g i n - r i g h t :   0 . 4 r e m ; 
 } 
 . c a r d - q u o t a   { 
         c o l o r :   v a r ( - - p r i m a r y - l i g h t ) ; 
         f o n t - w e i g h t :   5 0 0 ; 
 }  
 