InterviewStack.io LogoInterviewStack.io

Responsive and CSS Design Questions

Focuses on building adaptable, maintainable user interfaces across devices and screen sizes using CSS and responsive design principles. Topics include mobile first and adaptive strategies, media queries, fluid and relative units, responsive images and picture sources, layout techniques using Flexbox and CSS Grid, responsive typography and spacing, component breakpoints and adaptive components, writing efficient and maintainable styles with methodologies like BEM or CSS in JS, CSS custom properties for theming, handling interactive states and accessible focus styles, performance considerations for layout and animations, and how responsive work intersects with accessibility (touch targets, readable text, focus management). Candidates should be ready to explain implementation details, trade offs, and examples of responsive patterns they used.

HardTechnical
38 practiced
You receive pixel-perfect desktop mockups that must be converted into responsive components. Describe a step-by-step process to transform these static designs into responsive, accessible components: identifying content priorities, defining fluid scales for typography and spacing, selecting breakpoints (content-driven), implementing art direction for images, and collaborating with designers to resolve layout issues. Include how you'd prototype, test, and validate decisions with stakeholders.
HardSystem Design
42 practiced
Design a custom responsive grid system using CSS Grid and container queries that exposes a simple developer API: named grid areas, responsive column counts based on container size, and an easy way for component authors to specify column spans. Describe the CSS utilities or component props, how grid-template-columns is calculated (using custom properties), how container queries adjust layout, and provide usage examples for authors in the codebase.
MediumTechnical
47 practiced
Implement a responsive 'profile card' component using HTML and CSS (modern browsers). Requirements:- Desktop (>=768px): image on the left with a fixed width of 200px and content to the right filling remaining space.- Mobile (<768px): image stacked on top of content.- Image must preserve aspect ratio and be lazy-loaded.- Component must be accessible (alt text and semantic markup).Provide the minimum HTML and CSS solution and explain key choices.
HardTechnical
46 practiced
Design and compare approaches for a responsive masonry grid that supports dynamic content heights, is keyboard-accessible, and performs well for infinite scroll. Compare these approaches:- Using CSS columns,- Using CSS Grid with dense packing (where supported),- Using a JS-driven Masonry algorithm.Explain trade-offs in DOM order, accessibility, performance, and layout stability. If possible, provide a CSS-first implementation example and explain how you'd keep keyboard and screen-reader order logical.
EasyTechnical
47 practiced
Write the minimum HTML and CSS (no JavaScript) to implement a responsive two-column layout using Flexbox. Requirements:- On viewports >= 600px show two columns (left and right), each taking 50% of the row with a 16px gap.- On viewports < 600px stack into a single column.- Ensure images do not overflow their column and text wraps correctly.Assume modern browser support; provide accessible semantic HTML and the CSS rules.

Unlock Full Question Bank

Get access to hundreds of Responsive and CSS Design interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.